create or replace function CasLengthOfLongRaw( p_tname in varchar2,
p_cname in varchar2,
p_rowid in rowid ) return number
AUTHID CURRENT_USER as pragma autonomous_transaction;
l_length number;
begin
execute immediate
'insert into TEMPCSSRPLLOB(LOBFIELD)
select to_lob(' || p_cname || ')
from ' || p_tname || '
where rowid = :x' using p_rowid;
select dbms_lob.getlength(LOBFIELD) into l_length
from TEMPCSSRPLLOB;
commit;
return l_length;
end;
For this Function I am getting
error at Line 7 and ORA Error ORA-00932: inconsistent datatypes: expected LONG BINARY got BLOB ORA-06512: at "CASLENGTHOFLONGRAW", line 7 00932. 00000 - "inconsistent datatypes: expected %s got %s"