sql exception handling
Posted
by christine33990
on Stack Overflow
See other posts from Stack Overflow
or by christine33990
Published on 2010-04-04T08:03:25Z
Indexed on
2010/04/04
8:13 UTC
Read the original article
Hit count: 207
CREATE OR REPLACE PROCEDURE p_createLocaltable
IS
table_already_exist EXCEPTION;
PRAGMA EXCEPTION_INIT (table_already_exist, -00955);
BEGIN
create table local_table as
select * from supplied_table
where rownum < 1;
EXCEPTION
when table_already_exist then
DBMS_OUTPUT.put_line('Table already exists , does not need to recreate it');
END;
can anyone see any problem of the above code?
© Stack Overflow or respective owner