TD 6.0 with Oracle 11g

General discussion forum about all databases other than SqlBase.
demersj
Canada
Posts: 30
Joined: 12 Nov 2018, 13:38
Location: Ottawa, Canada

TD 6.0 with Oracle 11g

Post by demersj » 16 Apr 2012, 18:01

I just installed TD 6.0 with Oracle 11g and whenever I try to select from the database into a numeric variable, if the value returned from the database is a decimal, I get the message Error 104 "Attempt to fetch non numeric data into numeric column". My select is as simple as "Select 1/2 from dual into :nID" where nID is declared as a variable. Has anyone experienced this problem?

Christof
Germany
Posts: 191
Joined: 06 Mar 2017, 07:27
Location: Frankfurt, Germany

Re: TD 6.0 with Oracle 11g

Post by Christof » 17 Apr 2012, 07:22

You probably need to set some session parameters for your local requirements. For selecting decimal values you need to configure the session with the local decimal and group separators being used.
For example, for Germany we call something like this once right after obtaining the first Sql Handle for a session:

Code: Select all

Call SqlPrepareAndExecute( hSql, "ALTER SESSION SET NLS_NUMERIC_CHARACTERS = '.,'" )
Hth,
Christof

demersj
Canada
Posts: 30
Joined: 12 Nov 2018, 13:38
Location: Ottawa, Canada

Re: TD 6.0 with Oracle 11g

Post by demersj » 19 Apr 2012, 01:30

Great. It worked. Thanks a lot!

Return to “General Discussion”

Who is online

Users browsing this forum: [Ccbot] and 1 guest