month and 2000

From: Chairudin Sentosa Harjo <chai(at)prima(dot)net(dot)id>
To: pgsql-sql(at)postgresql(dot)org
Subject: month and 2000
Date: 1999-10-04 10:18:06
Message-ID: 37F87EDE.D69CE07F@prima.net.id
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Dear All,

Two questions:

One
---
How to select a date in order to get this form:
30-OCT-1999

I tried :
select date(sub_date) from tbl_date;
30-10-1999

What switch do I need to get 'OCT'?

Two
---
Why this happen?

tbs=> select date ('now');

date
----------
01-01-2000
(1 row)

I am sure the time on my computer is correct,
the year is 1999, the month is October
and the date is 4th.
Why the select gives 1st January 2000???

SuSE 6.2, Postgresql 6.5.2, Pentium III.

Regards,
Chai

Browse pgsql-sql by date

  From Date Subject
Next Message Steven M. Wheeler 1999-10-04 18:32:31 Re: [SQL] Questions about vacuum analyze
Previous Message raptor 1999-10-03 18:50:42 Re: [SQL] How about a postgreSQL cookbook?