[Dbix-class] data precision question

Alan Humphrey alan.humphrey at comcast.net
Tue Jan 31 00:34:27 GMT 2012


Alan Humphrey wrote:
> This is a FreeTDS/ODBC driver issue.  Still looking into it but isql also returns the truncated value.

Any luck with tracking this down?

> Yep.  Turns out this (4 decimal place money values are converted to 2 places) is considered a feature.  The driver returns the money value as a string which is then converted to a two-decimal place string value.  The options are to change the data type on the server or use the cast or convert functions in the SQL.  So, for the time being I'm using select/as in my resultsets to do the conversion.




More information about the DBIx-Class mailing list