Hi,

well, it worked testing in Python using the eGenix API even without setting the NLS_NUMERIC_CHARACTERS explicitly. Thus, I assume that the ODBC interface toward Python should be working automatically using default settings.

- thus I am guessing that it might be Zope that does not find the right environment variable. Tell me if I'm wrong.

Also, it is worth noting that I have converted to a Norwegian character set, whereas in http://www.osdir.com/ml/web.zope.database/2003-01/msg00036.html they are converting to a German character set. Might have something to do with reproducing the error.

-su





On Mon Feb 4 11:34 , "M.-A. Lemburg" <[EMAIL PROTECTED]>sent:

On 2008-02-04 08:19, siribu wrote:
> Hi,
>
> I found the a solution to the problem, it cannot be done just by " Leave scale 0
> floats untouched ?" which I tried, but also the Oracle parameter
> NLS_NUMERIC_CHARACTERS needed to be set explicitly.
> See http://www.osdir.com/ml/web.zope.database/2003-01/msg00036.html. That solved
> things for me.
>
> Anyway, thanks Marc-Andre :-)

You're welcome.

Could you explain why you had to set the NLS_NUMERIC_CHARACTERS variable ?

Is this needed for the ODBC driver to convert numbers to and from
strings correctly ?


> *On Sun Feb 3 12:37 , "M.-A. Lemburg" sent:
>
> *
>
> On 2008-01-23 14:35, siribu wrote:
> > Hi,
> >
> >
> >
> > I have got a problem:
> >
> >
> >
> > accessing an Oracle 10g database, whenever I ask for floats from a Zope Z SQL
> > method, they are automatically converted to integers, simply dropping the
> > decimal numbers.
> >
> >
> >
> > I am using Zope 2.10.4-final with Python 2.4.4 running on a Linux2 OS.
> > Furthermore, I am using UnixODBC with Easysoftâ€^(TM)s ODBC-Oracle driver
> together
> > with eGenix *mxODBC Zope DA*.
>
> There's a connection option " Leave scale 0 floats untouched ?" to switch
> this off.
>
> The truncation to integers is done because some database drivers always
> return numbers as floats - even integers. Zope would then display these
> as floats (without additional formatting), which may not look right to
> the user.
>
> > Running iSQL on the server or even utilizing the mxODBC Zope DA driver
> directly
> > in Python works well without problems.
> >
> >
> >
> > The error logs for the ODBC contained no sign or errors. Neither did I get
> any
> > response when I ran Event Log Manager in Zope. I could not find anything
> in syslog.
> >
> >
> >
> > Any clues on how to solve this?
>
> See above: just switch on the option in the connection properties.
>
> -
> Marc-Andre Lemburg
> eGenix.com
>
> Professional Python Services directly from the Source (#1, Feb 03 2008)
> > >> Python/Zope Consulting and Support ... http://www.egenix.com/
> <http://epost.start.no/mail/parse.pl\?redirect=http://www.egenix.com/>
> > >> mxODBC.Zope.Database.Adapter ... http://zope.egenix.com/
> <http://epost.start.no/mail/parse.pl\?redirect=http://zope.egenix.com/>
> > >> mxODBC, mxDateTime, mxTextTools ... http://python.egenix.com/
> <http://epost.start.no/mail/parse.pl\?redirect=http://python.egenix.com/>
> ________________________________________________________________________
>
> :::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,MacOSX for free ! ::::
>
>
> eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48
> D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg
> Registered at Amtsgericht Duesseldorf: HRB 46611
>
>
> -------------------------------------------------------------------------
> Få din egen, gratis e-postadresse på Start.no <http://www.start.no/>
>

--
Marc-Andre Lemburg
eGenix.com

Professional Python Services directly from the Source (#1, Feb 04 2008)
>>> Python/Zope Consulting and Support ... http://www.egenix.com/
>>> mxODBC.Zope.Database.Adapter ... http://zope.egenix.com/
>>> mxODBC, mxDateTime, mxTextTools ... http://python.egenix.com/
________________________________________________________________________

:::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,MacOSX for free ! ::::


eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48
D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg
Registered at Amtsgericht Duesseldorf: HRB 46611


------------------------------------------------------------------------- Få din egen, gratis e-postadresse på Start.no
_______________________________________________
Zope-DB mailing list
Zope-DB@zope.org
http://mail.zope.org/mailman/listinfo/zope-db

Reply via email to