Andreas Tille <[EMAIL PROTECTED]> writes:
> On Wed, 23 Aug 2000, hlefebvre wrote:
>> create table mytable( CreateDate timestamp default timestamp('now'),
>> ....);
> I've done a pg_dump <mydb> and there this line was transformed to:
> "createdat" timestamp DEFAULT '23.08.2000 15:35:16.00 CEST'::"timestamp",
This approach does not work in 7.0 (I think it did work in some prior
releases, but not recently). The recommended method is shown in the
FAQ:
4.22) How do I create a column that will default to the current time?
Use now():
CREATE TABLE test (x int, modtime timestamp default now() );
regards, tom lane