[Kde-pim] Problems with accessing Virtuoso via QtSql/ODBC

Tobias Koenig tokoe at kde.org
Thu Dec 31 17:51:27 GMT 2009


Hej,

I just tested to create a table in Virtuoso, fill it with some data
and retrieve them via SELECT again. While inserting values worked fine,
the SELECT statement didn't return anything. I crosschecked with isql
command line tool, the table contained the data, so QtSql is the culprit...

After some debuging I found out that the qsql_odbc driver has a switch
hasSQLFetchScroll (a boolean member variable) that stores whether the ODBC
driver supports SQL FetchScroll feature. It seems that Virtuoso reports that
it supports this feature, but when actually making use of it by calling
SQLFetchScroll (ODBC C-API) it returns error code for 'Non-supported operation'.
So it seems the Virtuoso guys have to fix their driver here.

After hardcoding false for hasSQLFetchScroll, I got 3 records returned correctly,
however the content of the VARCHAR(255) entries contained only the first character... ouch.
Ok, only first character smelled like unicode vs. non-unicode problem. Indeed there
is another switch inside the qsql_odbc driver that tells whether the ODBC driver
and the database server uses unicode. The detected value is 'true', however it doesn't
work like already mentioned. When hardcoding it to 'false' all entries are listed
completely, not only the first character.

So before these basic issues are fixed there is no way to use Virtuoso as backend
for Akonadi so far. AFAIKS the ODBC driver from Virtuoso must be fixed to report
the proper features.

@Sebastian, can you comment on that? Have you tested this already?

Ciao,
Tobias
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20091231/72dba895/attachment.sig>
-------------- next part --------------
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


More information about the kde-pim mailing list