David B wrote:
> We had been testing 7.4 for a few days and just noticed that some
> tables had created_timestamp rows with a date/time of the date the DB
> was created...not the date/time the insert was done.
>
> Looking at those tables the create DDL's for those few tables
> contained now ()
> as in:
>
> created_timestamp  timestamp DEFAULT now ()   -- note the space
> between now and ()
>
> Most had correctly been defined without the space - as in now()

Whatever it was, that was not the problem.  With 7.4.1:

peter=# create table test1 (foo text, create_timestamp timestamp default now());
CREATE TABLE
peter=# create table test2 (foo text, create_timestamp timestamp default now ());
CREATE TABLE
peter=# create table test3 (foo text, create_timestamp timestamp default now
peter(# /* blah */
peter(# (
peter(# /* blah */
peter(# )
peter(# )
peter-# ;
CREATE TABLE
peter=# \d test1
                      Table "public.test1"
      Column      |            Type             |   Modifiers
------------------+-----------------------------+---------------
 foo              | text                        |
 create_timestamp | timestamp without time zone | default now()

peter=# \d test2
                      Table "public.test2"
      Column      |            Type             |   Modifiers
------------------+-----------------------------+---------------
 foo              | text                        |
 create_timestamp | timestamp without time zone | default now()

peter=# \d test3
                      Table "public.test3"
      Column      |            Type             |   Modifiers
------------------+-----------------------------+---------------
 foo              | text                        |
 create_timestamp | timestamp without time zone | default now()

They're all identical.


---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
      subscribe-nomail command to [EMAIL PROTECTED] so that your
      message can get through to the mailing list cleanly

Reply via email to