The exec command returns a cursor object, which is a MATLAB structure with several fields that provides a link to the result returned from your query and several pieces of information about it. One of the fields of curs is the 'Data' field, which is set to 'No Data' when exec is first called. The fetch command puts data into the Data field. So to get the data out, you do something like this:
% begin code
curs=exec(conn,sqlquery);
curs=fetch(curs);
blob=curs.Data;
% end code
Note: Use curs=fetch(curs) instead of cr=fetch(curs). This doesn't overwrite the cursor object. It stores the fetched data in the data field. The way you have written your code, you'll have extra cursor objects lying around that you'll have to close.
Unfortunately, your method doesn't work. I still get answer
[1x1 oracle.sql.BLOB]
Thank you for you trying.
I have got the same problem. Even when I exactly copied the blob example from the matlab help (in the help files they say, that the return format is [21626x1 int8].
Did you find any solution.