2014-11-22 105 views
-3
create or replace procedure seqn (sname IN seq.seqname%type , 

startv IN seq.startval%type , 

incby IN seq.incrementby%type , 

maxi IN seq.maxilimit%type); 

    IS 
s_count integer ; 

    begin 
    select count(*) 
    into s_count 
    from sequence; 
    where seqname := sname ; 
if s_count := 0 
then 
    insert into seq 
    values(sname,startv,incby,maxi); 
end if; 

    end seqn ; 
    /

回答

0

我在您的程序中发现了四个错误。

首先,从下面的线的端卸下两个分号:

maxi IN seq.maxilimit%type); 
 from sequence; 

其次,不使用:=在以下两行比较值,使用=代替。

 where seqname := sname ; 
if s_count := 0 
+0

谢谢卢克伍德沃德.... – 2014-11-29 09:47:37