PostgreSQL – Valid Use Cases for TIME WITH TIME ZONE

database-designdatatypespostgresqltimetimezone

Along the lines of this related question:

Are there any valid use cases for actually using TIME WITH TIME ZONE or should it be considered an anti-pattern?

To be clear: I am asking about TIMEā€¦, not TIMESTAMPā€¦.

Best Answer

There is no valid use case. time with time zone is broken by design and only included in Postgres since it's in the SQL standard. Don't use it.

Time zones can have daylight saving time (DST) rules, which do not work with timetz at all.

In fact, the use of time with time zone is officially discouraged:

The type time with time zone is defined by the SQL standard, but the definition exhibits properties which lead to questionable usefulness. In most cases, a combination of date, time, timestamp without time zone, and timestamp with time zone should provide a complete range of date/time functionality required by any application.