Re: [GENERAL] hrs, mins and seconds do not appear with to_char
В списке pgsql-general по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: [GENERAL] hrs, mins and seconds do not appear with to_char |
| Дата | |
| Msg-id | 24929.1503866124@sss.pgh.pa.us обсуждение |
| Ответ на | [GENERAL] hrs, mins and seconds do not appear with to_char (Peter Koukoulis <pkoukoulis@gmail.com>) |
| Ответы |
Re: [GENERAL] hrs, mins and seconds do not appear with to_char
|
| Список | pgsql-general |
Peter Koukoulis <pkoukoulis@gmail.com> writes: > I am unsure as to why the hrs, mins and seconds do not appear for a date > column. Uh, because it's a date. > When performing the exact same queries in Oracle, I get the full date > formatted to "yyyymmddhh24miss", but cannot get the same for PostgreSQL, > for example: Oracle has a nonstandard notion of what "date" means, I believe. You probably want to use type "timestamp", and the to_timestamp() function, in PG if you want behavior similar to what Oracle is doing. https://www.postgresql.org/docs/current/static/datatype-datetime.html regards, tom lane
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера