International Problem (decimal point issue with OLE DB Provider)

From: Stewart McGuire (sNmOcSgPuAiMre_at_pirnie.com)
Date: 03/25/04

  • Next message: Stewart McGuire: "Re: International Problem (decimal point issue with OLE DB Provider)"
    Date: Thu, 25 Mar 2004 16:47:56 -0500
    
    

    I have an application that will be used internationally. I don't have to
    worry about different langauages because the company that will be using it
    standardizes on English for their business. However, they DO use the local
    standards for numeric display, dates, etc.

    My problem is this:

    I have floating point numbers stored in my DBF files.
    Apparently Visual FoxPro uses a period internally to represent decimals.
    Visual FoxPro has no problem displaying and working with that.
    I also have a modeling engine written in Visual C++ that uses ADO to read
    the data in, do calculations on it and write it back out.
    ADO is looking for a comma, in the case of Dutch (Holland). So a number
    that is stored as 3.14159 in the database is read in as 3.0 as the period is
    not interpreted as the decimal point.

    How do I get ADO to interpret the decimal point correctly when the
    application is run with a locale that does NOT use a period for the decimal
    point?
    Is there a way to tell ADO to use a period (without having to manually
    change the locale information)?
    Or is there a way to tell the Visual FoxPro OLE DB Provider what the correct
    decimal point character is so it interprets the numbers correctly? I found
    the "SET POINT TO" command in Visual FoxPro but found a page in the online
    help that says that command is not supported in the OLE DB provider.

    Any information would be extremely helpful!

    --Stewart McGuire
      Malcolm Pirnie, Inc.


  • Next message: Stewart McGuire: "Re: International Problem (decimal point issue with OLE DB Provider)"

    Relevant Pages

    • Re: International Problem (decimal point issue with OLE DB Provider)
      ... I just found out that VC++ doesn't set the default locale ... > Apparently Visual FoxPro uses a period internally to represent decimals. ... > ADO is looking for a comma, in the case of Dutch. ...
      (microsoft.public.fox.vfp.dbc)
    • Re: i know its a floating-point imprecision...
      ... i'm using float to store a fixed point exchange rate. ... So i was trying to go past Delphi's ADO wrapper and into ADO and it's ... And while checking how ADO handles floats and decimals, ... >> I understand that the value is stored in SQL Server using floating ...
      (microsoft.public.sqlserver.server)
    • Re: can I use ADO connection in VFP 6.0....??
      ... > Hi Eusebio, ... > You can use ADO in Visual FoxPro. ... > Microsoft Visual FoxPro Developers" by John V. Petersen. ... > Cindy Winegarden MCSD, Microsoft Visual Foxpro MVP ...
      (microsoft.public.fox.vfp.forms)
    • Re: can I use ADO connection in VFP 6.0....??
      ... You can use ADO in Visual FoxPro. ... Microsoft Visual FoxPro Developers" by John V. Petersen. ... Technical Articles section of the VFP6 documentation in the MSDN Library. ... Cindy Winegarden MCSD, Microsoft Visual Foxpro MVP ...
      (microsoft.public.fox.vfp.forms)
    • Re: can I use ADO connection in VFP 6.0....??
      ... I'm looking for a way to call a SQL Server Stored Procedure through ADO. ... I know how to do in VFP 6.0 with sqlexecutebut I don`t like to build the ... > Although you can use ADO in VFP, Visual FoxPro accesses data natively. ... > Use Customers In 0 Order CustID ...
      (microsoft.public.fox.vfp.forms)