X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 384A5D1BA93 for ; Wed, 3 Mar 2004 17:15:55 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 21166-04 for ; Wed, 3 Mar 2004 13:15:56 -0400 (AST) Received: from mail.dhs-club.com (mail.dhs-club.com [63.124.98.242]) by svr1.postgresql.org (Postfix) with ESMTP id 6E838D1B507 for ; Wed, 3 Mar 2004 13:15:49 -0400 (AST) Received: from dhs-club.com ([192.168.0.3]) (authenticated) by mail.dhs-club.com (8.11.6/8.11.3) with ESMTP id i23HFkb19152 for ; Wed, 3 Mar 2004 09:15:46 -0800 Message-ID: <40461395.5324CFEE@dhs-club.com> Date: Wed, 03 Mar 2004 12:19:17 -0500 From: DHS Webmaster Organization: The DHS Club X-Mailer: Mozilla 4.79 [en]C-CCK-MCD compaq (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: pgsql-admin Subject: bizarre AGE behaviour Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200403/15 X-Sequence-Number: 12585 Hello all, Many thanks for this fine product. We began encountering some unexpected date related errors this week and after further investigation found the following. We use the postgres AGE function in a custom function. The AGE function has begun to throw some unanticipated results back. This has not happened before and my first guess is that it may be leap year related. Here are some examples. This is good... network=# select age('04-01-04','03-01-04'); age ------- 1 mon (1 row) This isn't... network=# select age('05-01-04','03-01-04'); age --------------------- 1 mon 30 days 23:00 (1 row) Now it gets really strange...... network=# select age('06-01-04','04-01-04'); age --------------------- 1 mon 29 days 23:00 (1 row) This may have been addressed in the past (I subscribe to this list) and I just missed it, but is there a simple fix for this problem? Thanks. -- Bill MacArthur Webmaster The DHS Club, Inc. The Best Is Yet To Come!