A few years ago I’ve used libdbi in a C++ application to talk to MySQL and SQLite. At the time there was not much development being done in libdbi. In my current job we use Sybase on Solaris and I wanted to do development on one of their applications on Linux. I tried libdbi with the freetds driver.
There was a problem with conversion of VARCHAR to C string. If a field contained exactly the maximum number of characters specified by VARCHAR, the conversion would fail because there was not enough allocated to store the trailing 0 character.
I’ve submitted patches to both libdbi-drivers and freetds. The patch in freetds was not accepted but did result in some changes in the code doing the conversion. A second patch in libdbi-drivers fixed the problem.
patch 1
patch 2
discussion on freetds list
blog comments powered by Disqus
© Eddy Pronk