Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How do you handle exceptions. Give the syntax for it?

Answer Posted / guest

declare
khali exception;
a number(8);
b number(8);
begin
select count(*) into b from &table_name;
dbms_output.put_line('value of b is '||b);
if b = 0 then
raise khali;
end if;
exception
when khali then
dbms_output.put_line('are ye table to khali
nikali');
when others then
select NUM into a from furzi2;
dbms_output.put_line('Others');
end;
/

Is This Answer Correct ?    10 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are basic techniques of indexing?

1317


What are different types of sql commands?

1021


Difference between truncate, delete and drop commands?

1022


How do I count records in sql?

939


how to do backup entire database? : Transact sql

1065


How do I write a sql query in pgadmin 4?

923


What is ttitle and btitle?

1006


what is error ora-03113: end-of-file on communication channel?

1080


How delete a row in sql?

921


Does sql full backup truncate logs?

958


What is the most common sql injection tool?

991


Explain the advantages and disadvantages of stored procedure?

1075


what is a scheduled jobs or what is a scheduled tasks? : Sql dba

904


What does the argument [or replace] do?

1014


What are the different dml commands in sql?

1082