oracle简单存储过程以及如何查看编译错误
;
CREATE OR REPLACE PROCEDURE procedure_test IS
val VARCHAR2(200);
BEGIN
/* val := '';*/
SELECT uname INTO val FROM t_user;
END
;
select text from user_source where type='PROCEDURE' and name='PROCEDURE_TEST'
;
EXEC PROCEDURE_TEST;
execute procedure_test;
右键存储过程,重新编译;
然后执行
select * from SYS.USER_ERRORS where NAME = upper('PROCEDURE_TEST');
查看编译错误
;