Search Postgresql Archives

Question about inscrutable cast syntax

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Two versions of an application differ in the way a particular column is defined.

OLD:

lastupdated timestamp without time zone DEFAULT ('now'::text)::timestamp(6) with time zone NOT NULL

NEW:

lastupdated timestamp without time zone DEFAULT now() NOT NULL

I believe these are both the result of an automatic mysql-to-postgresql conversion process rather than hand-coded.

For my personal edification, I'd like to understand what's going on with that first one! Note that the column type is timestamp without time zone, so I'm also curious about the 'with time zone' modifier in the first example.

Thanks,
Kevin Murphy


--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux