Comma as a decimal symbol

P

Peter

Here's a tough one:
For the US among others the decimal symbol is a dot. Many countries, mine
with them, is using a comma instead. Now, when performing an SQL query with
a decimal number as an argument with the decimal symbol being a comma, the
query will fail: "Syntax error (comma) in query expression"
If I go to Control Panel -> >Regional and Language Options->Customize and
change the comma to a dot, the query will work as expected. However, running
the application on another computer would require this change as well. I'd
like to avoid Quick and Dirty solutions. I've tried to manually enter a dot
as the separator but Access just removes it making 2.3 become 23.
I'm using US English MS Access 2003 with US English XP SP2, always upgraded
with the lastest hotfixes. Is there a way to make Access honour the Regional
settings (Swedish)?
Regards
Peter
 
G

Guest

Better one ---
Replace([Money] & "",".",",")
--
KARL DEWEY
Build a little - Test a little


KARL DEWEY said:
Try this --
Payout: Int([Money]) & "," & Format(([Money]-Int([Money]))*100,"00")
--
KARL DEWEY
Build a little - Test a little


Peter said:
Here's a tough one:
For the US among others the decimal symbol is a dot. Many countries, mine
with them, is using a comma instead. Now, when performing an SQL query with
a decimal number as an argument with the decimal symbol being a comma, the
query will fail: "Syntax error (comma) in query expression"
If I go to Control Panel -> >Regional and Language Options->Customize and
change the comma to a dot, the query will work as expected. However, running
the application on another computer would require this change as well. I'd
like to avoid Quick and Dirty solutions. I've tried to manually enter a dot
as the separator but Access just removes it making 2.3 become 23.
I'm using US English MS Access 2003 with US English XP SP2, always upgraded
with the lastest hotfixes. Is there a way to make Access honour the Regional
settings (Swedish)?
Regards
Peter
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top