Up Prev Next
From: Stephen dot Sprague at morganstanley dot com
Subject: Re: numeric conversion behaviour
Date: Apr 7 2003 7:18PM
thank you, Michael. I missed seeing that attribute in the doc. I'll have a go
at that shortly.
On Mon, 7 Apr 2003 @ 12:04pm, an entity claiming to be Michael Peppler...:
mpeppl :On Mon, 2003-04-07 at 11:56, Stephen.Sprague@morganstanley.com wrote:
mpeppl :> Hi good people. I'm encountering this:
mpeppl :> I'm having problems using nsql via sybase::ctlib. seems the underlying
mpeppl :> call to ct_fetch on a numeric(20) column whose value is
mpeppl :> '1047389481776409' returns this '1.04738948177641e+15' in perl.
mpeppl :> This is certainly not desirable as it drops precision. It's probably due
mpeppl :> to the fact that the numeric is greater than 2^32. Is there anyway I can
mpeppl :> get the numeric to translate to a character string within ctlib? I have
mpeppl :> 'select *' all over my code; changing all references to explicitly state
mpeppl :> the column names is not an option I really want to undertake.
mpeppl :Short-term solution, use the UseNumeric database handle attribute.
mpeppl :See also the message from email@example.com a few days ago regarding
mpeppl :bug #261, which I claim was fixed in sybperl 2.11. However, the fix was
mpeppl :never correctly implemented (ahem!). I hope to have a fix for this in
mpeppl :the next few days.