Re: A creepy story about dates. How to prevent it?

Поиск
Список
Период
Сортировка
От scott.marlowe
Тема Re: A creepy story about dates. How to prevent it?
Дата
Msg-id Pine.LNX.4.33.0306190807340.7044-100000@css120.ihs.com
обсуждение исходный текст
Ответ на Re: A creepy story about dates. How to prevent it?  (Andrew Snow <andrew@modulus.org>)
Список pgsql-general
On Thu, 19 Jun 2003, Andrew Snow wrote:

>
> This is an old postgres "gotcha" that I've lived with since a long, long
> time ago.  It forced me to always use the datestyle YYYY-MM-DD so there
> is never any confusion in my programming.

create table p (d date);
CREATE TABLE
insert into p values ('2003-13-03');
INSERT 4530055 1
insert into p values ('2003-03-13');
INSERT 4530056 1
select * from p;
     d
------------
 2003-03-13
 2003-03-13

That doesn't fix it, it just makes it more obvious to the user how they
should insert.  If you switch the month/day pgsql STILL swaps them back
for you.




В списке pgsql-general по дате отправления:

Предыдущее
От: "Nigel J. Andrews"
Дата:
Сообщение: Re: attisdropped, * expansion and tg_trigtuple
Следующее
От: Ron Johnson
Дата:
Сообщение: Re: A creepy story about dates. How to prevent it?