Search Postgresql Archives

Re: Is it possible for PostgreSQL to support mmddyyyy date format?

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

 



This is from the link
1/8/1999 January 8 in MDY mode; August 1 in DMY mode
1/18/1999 January 18 in MDY mode; rejected in other modes
01/02/03 January 2, 2003 in MDY mode; February 1, 2003 in DMY mode; February 3, 2001 in YMD mode

 you can run this

select '01/01/2009'::date, '01-01-2009'::date

You can change the output  for the client..

http://www.postgresql.org/docs/current/static/runtime-config-client.html#GUC-DATESTYLE

Bernard Barton wrote:.
I'm currently porting an Informix based application to PostgreSQL 8.3. 
All of the dates processed by the application are in the mmddyyyy
format.  According to the date input table at the link below, the
mmddyyyy format is not listed.  The yyyymmdd format is supported, but
I'd have to modify a LOT of code to change the format, which I'm trying
to avoid.  Is there any way to get PG to work with the mmddyyyy date
format?  I know I can use the to_date function, but again, it would be
MUCH simpler if PG worked with this format.

-Thanks

http://www.postgresql.org/docs/current/static/datatype-datetime.html#DATATYPE-DATETIME-DATE-TABLE

  

[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