Re: [Vala] Problems retrieving binary data from a sqlite3 database BLOB column



Just summarizing what Alexey said, what you need is:

var data = (uint8[]) stmt.column_blob(4);
data.length = stmt.column_bytes(4);

You first get the data from Sqlite and then tell Vala about it's length. The
thing here is that Sqlite's API is not exactly Vala friendly, so you have to
do a bit more work then you usually need with Vala.

*Alexandre Rosenfeld*


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]