Received: from server.iclub.techno-link.com (server.cybernet.bg [212.36.3.249]) by hub.org (8.8.8/8.7.5) with ESMTP id NAA02742 for ; Sun, 31 May 1998 13:01:13 -0400 (EDT) Received: from localhost (marin@localhost) by server.iclub.techno-link.com (8.8.8/8.?.?) with SMTP id TAA18243; Sun, 31 May 1998 19:56:13 +0300 Date: Sun, 31 May 1998 19:56:13 +0300 (EET DST) From: Marin D X-Sender: marin@server.iclub.techno-link.com To: Bassel Hatoum cc: pgsql-sql@postgreSQL.org Subject: Re: [SQL] Trouble with dates In-Reply-To: <35708815.6D4E3AF3@gnc.net> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII CREATE TABLE test (d DATE); INSERT INTO test VALUES (CURRENT_DATE); test=> SELECT DATE( DATETIME(d) + '1 month'::TIMESPAN) FROM test; date ---------- 30-06-1998 (1 row) test=> Hope this helps... Marin -= Why do we need gates in a world without fences? =- On Sat, 30 May 1998, Bassel Hatoum wrote: > I'm trying to add months to a date without having to calculate how many > days in the month, etc. > Oracle has an add_month function that would do the trick. It there > anything similar in PGSQL? Or maybe a way to emulate it? > >