Create table arnold (
	a	int8,
	b	timestamp default 'epoch'::timestamp,
	c	timestamp default "timestamp"('epoch'::text)
);
I think that the best way forward for us (short of re-writing the backend to
use NULL) will be to just alter the default value to the one in column b in
the test table above.
Hmm. The "timestamp"() call is forcing TIMESTAMP WITHOUT TIME ZONE, which then gets converted to TIMESTAMP WITH TIME ZONE (adding in your one hour offset), which is the default for the unadorned, unquoted 'timestamp' type.

You can use something like

cast('epoch'::text as timestamp with time zone)

to get what you want, and can use "timestamptz"() if you insist. But that is not recommended for direct use in schema definitions, even if pgsql chooses to use it for dump/reloads at the moment.

- Thomas


---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org


Reply via email to