pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Richard Broersma Jr <rabroersma@yahoo.com>
To: Hiroshi Inoue <inoue@tpf.co.jp>
Cc: Greg Cocks <gcocks@stoller.com>
Cc: Postgresql ODBC List <pgsql-odbc@postgresql.org>
Subject: Re: possible ODBC bug with '-infinity'
Date: Mon, 3 Dec 2007 05:25:40 -0800 (PST)
Message-ID: <633255.45744.qm@web31809.mail.mud.yahoo.com> (raw)
In-Reply-To: <47526C0B.9060905@tpf.co.jp>

--- On Sun, 12/2/07, Hiroshi Inoue <inoue@tpf.co.jp> wrote:

> Do you think it is an appropriate handling ?

This is a good question.  I am not sure what an appropriate handling would be.  My first test of '-infinity' (which resulted in a raised error) was with an ado recordset.  Since you are questioning what is appropriate I thought that I should try a few different client front ends to see how they treated (+/-)infinity:

Client   |   -infinity       | + infinity
ADO      | <error>           |9999-12-31 23:59:59|
Access/LT|1899-11-30 00:00:00|9999-12-31 23:59:59|
OOB(ODBC)|0001-01-03 00:00:00|9999-12-31 23:59:59|

ADO = ado recordset created in VB
Access/LT = a linked tabled in MS-Access (probably DAO/ODBC?)
OOB(ODBC) = Open Office.org Base ODBC connection to the Database.

Having done further tests, it seems that the error must be a bug with ADO since other clients have not a problem with making -infinity equal to the smallest time stamp that their respective data type can display.  In my case, I do not really care about what time stamp values are displayed by the clients for (+/-) infinity since I use these values as an implied NULL value for time stamps.  Unfortunately, ADO is broken and can't display any value for -infinity.

> How do you think the driver should treat -infinity ?

It seems that it already handles it correctly. I was mistaken in thinking that the translation of (+/-) infinity was handled by ODBC. :o)
Regards,
Richard Broersma Jr.



view thread (11+ messages)  latest in thread

Message-ID: <633255.45744.qm@web31809.mail.mud.yahoo.com>
Permalink:  ../633255.45744.qm@web31809.mail.mud.yahoo.com/
Also on:    postgresql.org/message-id/633255.45744.qm@web31809.mail.mud.yahoo.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-odbc@postgresql.org
  Cc: rabroersma@yahoo.com, inoue@tpf.co.jp, gcocks@stoller.com
  Subject: Re: possible ODBC bug with '-infinity'
  In-Reply-To: <633255.45744.qm@web31809.mail.mud.yahoo.com>
  References: <47526C0B.9060905@tpf.co.jp> <633255.45744.qm@web31809.mail.mud.yahoo.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox