[freetds] Determining buffer size when retrieving data

Magnus Bäck magnus at dsek.lth.se
Sat Aug 14 19:29:09 EDT 2004

Is there a way to determine what destination buffer size is required
when using dbdata()/dbconvert() or dbbind() to retrieve and convert
column data of any type to string form? If not an exact number of bytes,
at least a worst-case figure? Because with newer protocol versions,
a CHAR or VARCHAR can hold >255 characters, yes? Trial-and-error with
increasing buffer size is of course always available, but it'd be nice
to avoid that method.

I have searched the FreeTDS documentation as well as Sybase's own,
and the archives for this list, but to no avail.

Magnus Bäck
magnus at dsek.lth.se

More information about the FreeTDS mailing list