15 pts.
 Copy a SQL Binary Large Object (BLOB) from one database to another
Is there  a way to find out the name of a Blob stored in a database. I am trying the code below and apparently the name is not correct.

SQL> Declare   2   tpsr Blob;   3   spsr blob;   4  Begin   5   Select '8502' into tpsr from ca90joetmp.spec_form_psr where spec_form_id = '90710';   6   Select '8502' into tpsr from specdev_mst.spec_form_psr where spec_form_id = '29401';   7   DBMS_LOB.COPY (tpsr,spsr,600000,1,1);   8       9  end;  10  / Declare * ERROR at line 1: ORA-06502: PL/SQL: numeric or value error: invalid LOB locator specified: ORA-22275 ORA-06512: at "SYS.DBMS_LOB", line 420 ORA-06512: at line 7



Software/Hardware used:
Oracle 10g
ASKED: October 14, 2010  7:01 PM
UPDATED: October 14, 2010  7:56 PM

Answer Wiki:
I don't know what you are trying to do. I suppose it is some kind of test. Also, I don't see much relation between the question title and the code you posted. <b>You are getting the error because your source blob is null.</b> I would recommend taking a look at this: <a href="http://soft.buaa.edu.cn/oracle/bookshelf/oreilly/bipack/ch08_03.htm">DBMS_LOB Interface</a> But I think you are completely new to PL/SQL. If that is true, I think you should start learning the basics before trying to manipulate blobs.
Last Wiki Answer Submitted:  October 14, 2010  7:56 pm  by  carlosdl   63,535 pts.
All Answer Wiki Contributors:  carlosdl   63,535 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _