Currently, LibreOffice allocates (in ODBC connections) a buffer of size 20 for bookmarks. This usually suffices, but there is no guarantee that it does.
The size is set in connectivity/source/drivers/odbcbase/OResultSet.cxx:
const SQLLEN nMaxBookmarkLen = 20;
This should be changed to querying the maximal size at runtime with SQLColAttribute (called on column 0), and that's the size of the buffer we need.
Hopefully this will not trigger bugs in ODBC drivers... Maybe we should take the biggest of the value returned by SQLColAttribute and the current 20?
Do you know a driver which uses longer bookmarks? Perhaps a free driver?
(In reply to comment #1)
> Do you know a driver which uses longer bookmarks?
No, I don't.
Adding self to CC if not already on
Migrating Whiteboard tags to Keywords: (easyHack, difficultyInteresting, skillCpp, skillSql)
JanI is default CC for Easy Hacks (Add Jan; remove LibreOffice Dev List from CC)