The PostgreSQL timestamp combines the functionality of the PostgreSQL date and time types into a single data type. The syntax of a timestamp value consists of a valid date format, followed by at least one whitespace character, and a valid time format. It can be followed optionally by a time zone value, if specified.

Combinations of all date and time formats listed in Table 3-15 and Table 3-20 are each supported in this fashion. Table 3-22 illustrates some examples of valid timestamp input.

Table 3-22. Some Valid Timestamp Formats

Format Example

Description

1980-06-25 11:11-7

ISO-8601 date format, with time detailed to minutes, and PST time zone

25/06/1980 12:24:11.112

European date format, with time detailed to microseconds

06/25/1980 23:11

US date format, with time detailed to minutes in 24-hour time

25.06.1980 23:11:12 PM

German regional date format, with time detailed to seconds, and PM attached

Warning Time Zones and Timestamps
 

While PostgreSQL supports the syntax of creating a column or value with the type timestamp without time zone , as of PostgreSQL 7.1.2 the resultant data type still contains a time zone.