Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"

Re: DBD::ODBC FoxPro double type numbers rounded

by afoken (Canon)
on Apr 23, 2019 at 07:37 UTC ( #1232895=note: print w/replies, xml ) Need Help??

in reply to DBD::ODBC FoxPro double type numbers rounded

I vaguely remember that you can pass some attributes to prepare or bind to help DBI / DBD::ODBC with the correct data types. In your case, you need to mark the result column as floating point number (instead of int / string). See bind_col in DBD::ODBC.

In general, DBI / DBD::ODBC should be able to auto-detect the type of any result column, but it seems that something got messed up with FoxPro. Perhaps FoxPro wrongly reports the column as some integer type at the ODBC level.


Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)
  • Comment on Re: DBD::ODBC FoxPro double type numbers rounded

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1232895]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (2)
As of 2022-05-21 00:35 GMT
Find Nodes?
    Voting Booth?
    Do you prefer to work remotely?

    Results (76 votes). Check out past polls.