Skip to content

Commit a68e14f

Browse files
committed
Explicitly disclaim support for time with time zone
1 parent ea9610f commit a68e14f

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

pgtype/time.go

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,11 @@ type TimeValuer interface {
1919

2020
// Time represents the PostgreSQL time type. The PostgreSQL time is a time of day without time zone.
2121
//
22-
// Time is represented as the number of microseconds since midnight in the same way that PostgreSQL does. Other time
23-
// and date types in pgtype can use time.Time as the underlying representation. However, pgtype.Time type cannot due
24-
// to needing to handle 24:00:00. time.Time converts that to 00:00:00 on the following day.
22+
// Time is represented as the number of microseconds since midnight in the same way that PostgreSQL does. Other time and
23+
// date types in pgtype can use time.Time as the underlying representation. However, pgtype.Time type cannot due to
24+
// needing to handle 24:00:00. time.Time converts that to 00:00:00 on the following day.
25+
//
26+
// The time with time zone type is not supported. Use of time with time zone is discouraged by the PostgreSQL documentation.
2527
type Time struct {
2628
Microseconds int64 // Number of microseconds since midnight
2729
Valid bool

0 commit comments

Comments
 (0)