|
-
Oct 20th, 2000, 09:40 AM
#1
Thread Starter
New Member
Hi all friends!
I have a little problem with an application that reads
data from an oracle DB.
Here in sweden we uses "," as decimal separator for ie. currency.
My application collects a number of rows with items and items prices and prints them on an invoice.
The problem is that ADO strips "," from items prices and thus adding the item value by a hundred times.. ie. "16,22" becomes "1622" in the recordset price field.
The field in question has adNumeric as data type.
What must I do to get the "," to stay in place??
regards,
Jesper
-
Oct 21st, 2000, 03:53 AM
#2
Frenzied Member
There may be an international setting that needs to be set on the Oracle server (Or the PC running the app). Check Regional settings on your client PC and if your running Oracle server on a NT box, check it there as well.. If you running it on a Unix box you will have to check an Oracle manual.
Also, when setting up your ODBC DSN, check to see if it is configured to use Regional Settings.
oOOo--oOOo
__ /\/\onte96
oOOo--oOOo
Senior Programmer/Analyst
MCP
[email protected]
[email protected]
Your results may vary.. some restrictions may apply.. pricing and participation may vary.. not available in all states.. professional driver closed course..quantities limited..
-
Oct 25th, 2000, 06:33 AM
#3
Thread Starter
New Member
Hi!
Other programs like Winsql using the same DSN gets the right number format.. It's only my ADO VB project that gets it all wrong..
Therefore I think that there must be some sort of switch or delimiter setting somewhere that needs to be tuned.
Regards,
Jesper
-
Oct 25th, 2000, 12:03 PM
#4
Frenzied Member
monte is right
there is an international setting that needs to be changed to . so that it will stay..
i remember changing it from "." to "," and vise versa but i forgot how..
-
Oct 25th, 2000, 01:15 PM
#5
Thread Starter
New Member
I'm not saying he is wrong. Just wondering why other applications using the same drivers and same system DSN can retreive the information correctly and VB (ADO) can't.
I learnt today that by using ' around the fieldname in the sql-query ADO is forced to accept "," as decimal notation. Haven't tried it yet though.
/jesper
-
Oct 25th, 2000, 02:21 PM
#6
Frenzied Member
easier solution would be to have all those european countries use the DOT instead 
hehhe
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|