Can you try binding it as a varchar? Instead of setting the default bind type to SQL_DOUBLE, which will cause more problems than it will help for the most part, try setting it to 12 (SQL_VARCHAR) Thanks, Jeff
________________________________ From: Wim Livens [mailto:[EMAIL PROTECTED] Sent: Tue 9/20/2005 8:11 AM To: dbi-users@perl.org Subject: Error writing to double using ODBC I'm having trouble writing to columns of type DOUBLE using ODBC (to Pervasive.SQL) $dbh = DBI->connect('dbi:ODBC:DEMODATA','','',{RaiseError => 1, PrintError =>1}) or die $DBI::errstr; $sth=$dbh->prepare("update mytable set mycolumn=? where id=123") || die $DBI::errstr; $value=3/2; $sth->execute($value) || die $DBI::errstr; Yields: DBD::ODBC::st execute failed: [Pervasive][ODBC Client Interface][LNA][Pervasive][ODBC Engine Interface]Error converting to numeric type: Parameter #1. (SQL-22018)(DBD: st_execute/SQLExecute err=-1) My platform: perl, v5.8.7 built for cygwin-thread-multi-64int DBI version 1.48 DBD::ODBC vesrion 1.13 Pervasive.SQL 08.60.0192 030 $dbh->column_info correctly gives SQL_DOUBLE I also tried these but they don't make any difference. $sth->bind_param(1, $value, SQL_DOUBLE); $dbh->{odbc_default_bind_type}=SQL_DOUBLE; $dbh->do("set decimalseparatorcomma=OFF"); Any hints ? Thanks, Wim.