How about:

SELECT '2001-03-06'::timestamp + '1 Year';

Hope that helps,

Mike Mascari


-----Original Message-----
From:   Boulat Khakimov [SMTP:[EMAIL PROTECTED]]
Sent:   Tuesday, March 06, 2001 2:20 PM
To:     [EMAIL PROTECTED]; [EMAIL PROTECTED]; 
[EMAIL PROTECTED]
Subject:        [GENERAL] Date question

Hi,

Im a little bit stuck here.

Does anyone know how to get date in format 'YYYY-MM-DD' of a date one
year from now.
So for example today is '2001-03-06' I need to get date 12 months from
now
which will be '2002-03-06' in todays case...

In mysql I used  DATE_ADD(CURDATE(), INTERVAL 12 MONTH) , but that
doesnt work in PG.


Regards,
Boulat Khakimov


-- 
Nothing Like the Sun

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to [EMAIL PROTECTED] so that your
message can get through to the mailing list cleanly


---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to [EMAIL PROTECTED] so that your
message can get through to the mailing list cleanly

Reply via email to