Vikram Ambrose writes: > I can't seem to get BLOBs to work with SQLite. > > Here is some test code. > http://en.pastebin.ca/2026862 > > Output on my machine is; > > dbi_conn_connect: rv = 0: > data = ERROR > > What am I doing wrong?
Probably nothing, at least not in your own code. Your test code prints the following on my box: $ ./sqlite_binary_test dbi_conn_connect: rv = 0: dbi_conn_query: data = close your eyes, this is binary All I changed is the driver. I've used sqlite3 as I currently don't have sqlite installed. However, as far as I can see there is no difference between those drivers in terms of blob handling. Could you test sqlite3 as well just to see whether it is a problem of your box or indeed a problem of the driver. Did you run make check in libdbi-drivers after building and installing the drivers? The test program includes checks for blob handling, so if there is a problem in the driver it should report errors. Runs fine here. Also, could you send a few specs of your OS and libdbi/libdbi-drivers versions? regards, Markus P.S. your code contains a strlen() call on binary data. I assume you are aware that this wouldn't work with arbitrary binary data. -- Markus Hoenicka http://www.mhoenicka.de AQ score 38 ------------------------------------------------------------------------------ Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ libdbi-users mailing list libdbi-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libdbi-users