I have a small PL/SQL Block
assume in this way
begin
select * from emp where empno=100;
exception
when others then
<Some Messages>
when no_data_found then
<Some Messages>
when too_many_rows then
<Some Messages>
end;
The question which he asked was whether this block will get
executed normally or it will throw error ?
If errored out then what is the reason for the error ?
Could anybody please help me ?
Regards
Nakul Venkataraman
Answer Posted / virendra
yes this will give error, as in exception block when others
should be at the bottom of the exception block.
ex.
exception
when no_data_found then
<Some Messages>
when too_many_rows then
<Some Messages>
when others then
<Some Messages>
end;
Is This Answer Correct ? | 19 Yes | 3 No |
Post New Answer View All Answers
How is data stored on a disk?
Is record in pl sql?
What is Materialized View? In What Scenario we Use Materialized View?
How do you remove duplicates without using distinct in sql?
How to fix oracle error ora-00942: table or view does not exist
Which is the correct statement about truncate and delete?
what is the difference between clustered and non clustered index in sql? : Sql dba
Can we rollback truncate?
What is the command used to fetch the first 5 characters of a string?
What are different types of statements supported by sql?
How do you declare a user-defined exception?
What is a mutating table and a constraining table?
How many aggregate functions are available there in sql?
What is function and procedure in pl sql?
Are left and right joins the same?