Article View: borland.public.cppbuilder.database.ado
Article #509Re: Float field format mimatching in query
From: Viatcheslav V. Vassiliev
Date: Fri, 26 Aug 2005 13:20
Date: Fri, 26 Aug 2005 13:20
38 lines
2439 bytes
2439 bytes
AFAIK, MS SQL Server always expects dot as decimal separator in queries. For time/date, you may use CONVERT function in query, it has parameter to specify date style. Other DBMS may work another way. //------------------------------------------ Regards, Vassiliev V. V. http://www.managed-vcl.com - using .Net objects in Delphi for Win32 + ADO.Net http://www.oledbdirect.com - The fastest way to access MS SQL Server, MS Jet (Access) and Interbase (through OLEDB) "Michele Santucci" <michele.santucci@celinavio.it> �������/�������� � �������� ���������: news:430ecb7e@newsgroups.borland.com... >> Setting DecimalSeparator = '.' will use '.' for convertion. Parameters >> may be added at runtime too. > > > > This's exactly what I would like to avoid since I cannot be sure of what > type > of separator the system locale and the database engine are using. > > How can I get what separator or more generally what float format is used > into > a database ? > > How can I get what time separator or more generally what time/date format > i > used into a database ? > > I tried to set the locale of the application with this: > > setlocale( LC_ALL, "Italian_Italy.1252" ); > > but this's not enough ... > >
Technical Details
Message-ID:
<430f16de@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!newspeer.tds.net!38.119.100.82.MISMATCH!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mailReferences:
<430c51e0@newsgroups.borland.com> <430d5e97$1@newsgroups.borland.com> <430d93fd@newsgroups.borland.com> <430ec2e1$1@newsgroups.borland.com> <430ecb7e@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10698b,f2763377f03f683f X-Google-Attributes: gid10698b,public X-Google-Language: ENGLISH,ASCII From: "Viatcheslav V. Vassiliev" <support@oledbdirect.com> Newsgroups: borland.public.cppbuilder.database.ado References: <430c51e0@newsgroups.borland.com> <430d5e97$1@newsgroups.borland.com> <430d93fd@newsgroups.borland.com> <430ec2e1$1@newsgroups.borland.com> <430ecb7e@newsgroups.borland.com> Subject: Re: Float field format mimatching in query Date: Fri, 26 Aug 2005 17:20:01 +0400 Lines: 40 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.2527 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 X-RFC2646: Format=Flowed; Response NNTP-Posting-Host: 85.93.138.132 Message-ID: <430f16de@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1125062366 85.93.138.132 (26 Aug 2005 06:19:26 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!newspeer.tds.net!38.119.100.82.MISMATCH!news-out.newsgroups.com!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail