I have a MariaDB (MySQL compatible) 10 database with a table that has a BLOB column that holds an image.
I am using the Mysql 8 ODBC connector.
Connecting through a macro (created an UNO service) works fine and I get an XResultSet, which is stored in a variable named oResultSet.
The problem occurs when I attempt to get the blob data with
An exception occurred Type: com.sun.star.sdbc.SQLException Message: The driver does not support the function 'XRow::getBlob'..On Line 156 Aborting....
It seems that the Mysql ODBC connector does support blobs, based on this:
But maybe the mapping is wrong?
What I want to accomplish is get the binary data from the database and set the image data to an image control.
Thanks for the input!
I’ve changed my approach.
I edited the table to be a varchar instead of a blob and am using oResultSet.getString instead.
So, now I have path to an image, C:\images\myimage.jpg, for example.
How do I load the image data from that file into the Image Control?