Search Postgresql Archives

Re: How to get DATE in server locale format

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

 



You might be able to get what you want with the to_char() function,
if setting datestyle doesn't do the trick for you.

setting datestyle changes style for whole sql statement.

How to get this in a single conversion in sql statement so that other expressions in same sql statement are not affected.

to_char() requires hard-coded format.
Different servers have different locales so that format is not know at application design time.

How to get localized date for single conversion inside SELECT statement so that it works in different server lc_time settings ?

Andrus.

--
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