We have developed a project that runs over several database engines with de ADODB php library. At this moment it's runing over MySQL, MSSQL Server and Informix through the Linux Informix Client SDK ODBC driver.

We need to store non-printable characters into varchar fields (ASCII code below 32). This works OK in Mysql , MSSQL Server and Informix through ODBC.

We've built the PHP4 4.3.2 Informix module in a Debian Woody to avoid the ODBC overload. All seems OK except when we try to insert something like this:

$sql = "INSERT INTO table (txt) VALUES ( chr(3).chr(5)."Hello" )";

Informix returns an error of Invalid character.

In fact, the same query with the ODBC driver runs without problems.

Well, is there any trick to avoid this problem?
Is possible to escape these characters?

Thanks a lot in advance !

Sorry for my English, I'm not a native speaker.

Agustí Fita.

-- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to