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 DAA14546 for ; Tue, 2 Jun 1998 03:43:11 -0400 (EDT) Received: from localhost (marin@localhost) by server.iclub.techno-link.com (8.8.8/8.?.?) with SMTP id KAA06893 for ; Tue, 2 Jun 1998 10:36:59 +0300 Date: Tue, 2 Jun 1998 10:36:58 +0300 (EET DST) From: Marin D X-Sender: marin@server.iclub.techno-link.com To: pgsql-sql@postgresql.org Subject: timespan weirdness (fwd) Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Hi! I need some help on the following timspan results: create table test(d date); insert into test values('1-5-98'); // European format test=> select * from test; d ---------- 01-05-1998 (1 row) // this is OK test=> select date(datetime(d) + '1 month'::timespan) from test; date ---------- 01-06-1998 (1 row) // this is OK test=> select date(datetime(d) + '5 months'::timespan) from test; date ---------- 01-10-1998 (1 row) // Ooops! test=> select date (datetime(d) + '6 months'::timespan) from test; date ---------- 31-10-1998 (1 row) // Ok too... test=> select date (datetime(d) + '13 months'::timespan) from test; date ---------- 01-06-1999 (1 row) Any comments? Than for your help! Marin -= Why do we need gates in a world without fences? =-