[Zope-dev] Again... Fw: [Zope] DCOracle/ZOracleDA not returning floats!!!
Karl Putland
kputland@servicemagic.com
Mon, 7 Feb 2000 15:28:44 -0700
Looking for others to confirm that this is indeed a problem.
----- Original Message -----
From: "Karl Putland" <kputland@servicemagic.com>
To: "Zope@Zope. Org" <zope@zope.org>
Sent: Thursday, February 03, 2000 3:49 PM
Subject: [Zope] DCOracle/ZOracleDA not returning floats!!!
> >>> sql = """select sysdate, 0.111, 1234.123456, 123, 1234,
> (sysdate-to_date('2000-02-03','YYYY-MM-DD')) DateDiff from dual"""
> >>> c.execute(sql)
> >>> c.description
> (('SYSDATE', 'DATE', 75, 7, 0, 0, 1), ('0.111', 'NUMBER', 40, 3, 0, 0, 1),
> ('1234.123456', 'NUMBER', 40, 6, 0, 0, 1), ('123', 'NUMBER', 40, 3, 0, 0,
> 1), ('1234', 'NUMBER', 40, 3, 0, 0, 1), ('DATEDIFF', 'NUMBER', 40, 22, 0,
0,
> 1))
> >>> pprint.pprint(c.fetchone())
> (dbiDate('2000-02-03 15:38:23'), 0, 1234, 123, 1234, 0)
> >>>
>
>
> A similar query executed through ZOPE has the same effeect.
>
> Z SQL Method at /db / prod / Oracle / Test_Junk
>
> --------------------------------------------------------------------------
--
> ----
> SYSDATE 0.111 DATEDIFF
> 2000/02/03 15:36:35 US/Mountain 0 0
>
> --------------------------------------------------------------------------
--
> ----
> SQL used:
>
> select sysdate, 0.111, (sysdate-to_date('2000-02-03','YYYY-MM-DD'))
DateDiff
> from dual
>
>
> --------------------------------------------------------------------------
--
> ----
>
>
>
>
> The same query executed though ODBC returns the desired result
>
> Z SQL Method at /db / prodODBC / Oracle / Test_Junk
>
> --------------------------------------------------------------------------
--
> ----
> SYSDATE 0.111 DATEDIFF
> 2000/02/03 15:41:12 US/Mountain 0.111 0.653611111111
>
> --------------------------------------------------------------------------
--
> ----
> SQL used:
>
> select sysdate, 0.111, (sysdate-to_date('2000-02-03','YYYY-MM-DD'))
DateDiff
> from dual
>
>
> --------------------------------------------------------------------------
--
> ----
>
>
> Please help.
>
> -Karl
>
>
> _______________________________________________
> Zope maillist - Zope@zope.org
> http://lists.zope.org/mailman/listinfo/zope
> ** No cross posts or HTML encoding! **
> (Related lists -
> http://lists.zope.org/mailman/listinfo/zope-announce
> http://lists.zope.org/mailman/listinfo/zope-dev )
>