怎么写oracle存储过程,在没有输入相应的内容时,会出提示框?
1、RAISE_APPLICATION_ERROR(error_number,error_message,[keep_errors]);
2、error_number是从–20,000到–20,999之间的参数,这样就不会与ORACLE的任何错误代码发生冲突;
3、error_message 是相应的提示信息(< 2048 字节)。
keep_errors为可选,如果keep_errors=TRUE,则新错误将被添加到已经引发的错误列表中。如果keep_errors=FALSE(缺省),则新错误将替换当前的错误列表。
oracle存储过程中提示 错误:PLS-00103: 出现符号 "FOR"在需要下列之一时
你妹,你那个语法是sql server的语法好伐。。。
oracle语法见下面
declare
cursor v_cur_tmp is
SELECT oc_date,dwbm,kmbm,bzbm,rowid FROM t_gfsindex_indexcontent;
begin
open v_cur_tmp;
loop
fetch v_cur_tmp into v_oc_date, v_cur_dwbm, v_cur_kmbm, v_cur_bzbm,cur_rowid;
exit when v_cur_tmp%NOTFOUND;
;
end loop;
close v_cur_tmp;
end;