I could not send a sequence next value directly as a parameter in a pl/sql block. Then, 🙂
begin
pr_insert_mytable
(
mytable_seq.NEXTVAL ,
xx,
yy,
0,
zz,
);
end;
Error: PLS-00357: Table,View Or Sequence reference mytable_seq.NEXTVAL not allowed in this context
Line: 301
Text: pr_insert_log(mytable_seq.NEXTVAL,
Error: PL/SQL: Statement ignored
Line: 301
Text: pr_insert_mytable(mytable_seq.NEXTVAL,
then we can set it the sequence to a variable then insert it 🙂
declare
ln_id number(10);
begin
select mytable_seq.NEXTVAL into ln_id
from dual;
pr_insert_mytable
(
ln_id,
xx,
yy,
0,
zz,
);
end;
11g solved the problem – http://technology.amis.nl/blog/?p=2268