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...

While inserting 10 rows using procedure, if 3rd entry is
having some error, what will be the output? How u will
handle that error?

Answer Posted / raji_4u

IF THE PROCEDURE HAS AN EXCEPTION HANDLER,THEN ALL THE
RECORDS ARE INSERTED EXCEPT THE 3rd RECORD.

IF THE PROCEDURE DOES NOT HAVE THE EXCEPTION HANDLER, THE
EXCEPTION PROPAGATES TO THE CALLING BLOCK'S EXCEPTION SECTION.
IF THE EXCEPTION IS HANDLED, ONLY THE FIRST TWO RECORDS ARE
INSERTED ie(1st, 2nd).

IF THE CALLING BLOCK ALSO DOES NOT HANDLE THE EXCEPTION, NO
RECORDS ARE INSERTED SINCE THE TRANSACTION IS ROLLED BACK.

IF YOU WANT TO HANDLE THE ERROR, PLACE A EXCEPTION HANDLER
IN THE PROCEDURE AND LOG THE ERROR. THIS MAKES ONLY THE 3rd
RECORD TO ROLLBACK AND ALL OTHER RECORDS ARE INSERTED.

Is This Answer Correct ?    7 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Give the order of sql select?

1132


What is foreign key in sql with example?

921


Why triggers are used?

981


What is case function?

1034


what are integrity rules?

1020


what is the difference between ereg_replace() and eregi_replace()? : Sql dba

1140


What is form and report?

970


Is it possible to sort a column using a column alias?

1034


Does sql view stored data?

947


Can we use ddl statements in stored procedure sql server?

1003


How many types of indexes are there in sql?

977


Who is the owner of mysql database?

1053


What are the steps for performance tuning.

1326


What are the sql versions?

935


Is sql between inclusive?

1117