Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Function may not be use in SQL - PLS-00231

573518Oct 31 2007 — edited Nov 1 2007
Here is my code,

-- Database 10g Enterprise Edition Release 10.2.0.2.0
declare
v1 varchar2(2000);
function test_func ( v2 varchar2) return varchar2
is
begin
return v2 || 'x' || v2;
end;
begin
-- ok
v1 := test_func('Hello');
--- Error PLS-00231: Function may not be used
--insert into xxxx values test_func(….
select test_func('World') into v1 from dual;
end;

I don’t want to define test_func in database as a stand-alone/package function. Is there any other way in 10G.

Thanks.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 29 2007
Added on Oct 31 2007
11 comments
12,522 views