PL\SQL で複数のif
条件を使用しようとすると、エラーが発生します。
ORA-06550: line 16, column 5:
PLS-00103: Encountered the symbol "LOOP" when expecting one of the following:
if
ここに私のコードがあります:
declare
price_var number;
st_numb number;
co_pr number;
cursor student_count is select STUDENT_NUMBER,COURSE_PRICE from COURSES;
begin
open student_count;
loop
fetch student_count into st_numb,co_pr;
if st_numb<10 then
update COURSES set COURSE_PRICE=co_pr*1.05;
elseif st_numb>10 then
update COURSES set COURSE_PRICE=co_pr*1.07;
end if;
exit when student_count%notfound;
end loop;
end
エラーがどこにあるか教えてもらえますか? ありがとう。