Anuj Singh Oracle DBA
Saturday, 15 October 2011
ORA-01476: divisor is equal to zero
to avoid ORA-01476: divisor is equal to zero
declare
n1 number := 155;
n2 number := 0;
begin
n1 := n1/n2; -- divide by zero
dbms_output.put_line(n1);
exception
when ZERO_DIVIDE
then dbms_output.put_line('You Divided by Zero');
end;
/
No comments:
Post a Comment
‹
›
Home
View web version
No comments:
Post a Comment