Home » SQL & PL/SQL » SQL & PL/SQL » How to handle BLOB data  () 1 Vote
icon5.gif  How to handle BLOB data [message #191533] Thu, 07 September 2006 00:57 Go to next message
manish5.k
Messages: 9
Registered: September 2006
Junior Member
Hi frnds

i am getting difficulty in handling BLOB data.
i am using QT as UI and want to get the blob data stored in the databse. i have done that thing by a procedure, which converts BLOB to RAW. If i execute the produre from sql prompt. it is showing the result, but in QT it is giving this error

QOCI9Result::reset: unable to execute statement: ORA-06553: PLS-306: wrong number or types of arguments in call to 'READ_BLOB_EXAMPLE'

what is this error:ORA-06553

Hoping to get quick reply
manish
manish5.k@tcs.com
Re: How to handle BLOB data [message #191553 is a reply to message #191533] Thu, 07 September 2006 02:03 Go to previous messageGo to next message
Frank
Messages: 7880
Registered: March 2000
Senior Member
what is the signature of READ_BLOB_EXAMPLE and how do you call it?
Re: How to handle BLOB data [message #191563 is a reply to message #191553] Thu, 07 September 2006 02:24 Go to previous message
manish5.k
Messages: 9
Registered: September 2006
Junior Member
i am giving u the procedure code, i m using along with errors..
i am using this procedure to convert the BLOB data into Raw data

create or replace procedure read_blob_example(
id_par in integer, binary_buff_var out RAW
) IS
blob_var BLOB;
offset_var INTEGER :=1;
amount_var INTEGER :=25;
BEGIN

initialize_blob(blob_var, id_par);
DBMS_LOB.READ(blob_var, amount_var, offset_var,binary_buff_var);
DBMS_OUTPUT.PUT_LINE(' amount_var = ' || amount_var);
DBMS_OUTPUT.PUT_LINE(' binary_buff_var = ' || binary_buff_var );
END read_blob_example;

i have checked this procedure by calling it with another procedure, it is returning the rigt output.
Data in the table with blob colum is '10010101110111101'
which i m getting from calling other procedure.

In QT, i have written

QSqlQuery query;
query.prepare( "call read_blob_example(?, ?)" );
query.bindValue( 0, 1 );
query.bindValue( 1, 0, QSql:out );
query.exec();
txaClob->setText(query.boundValue( 1 ).toByteArray());

Errors that i got now...
QOCI9Result::reset: unable to execute statement: ORA-06553: PLS-306: wrong number or types of arguments in call to 'READ_BLOB_EXAMPLE'


Previous Topic: How to reset the culmalative balance
Next Topic: indexes storing.
Goto Forum:
  


Current Time: Wed Dec 07 10:39:12 CST 2016

Total time taken to generate the page: 0.09145 seconds