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


Can we have exception part in trigger ?



Can we have exception part in trigger ? ..

Answer / kishore

yes........

create or replace trigger emp_biu
before insert or update on employee
referencing new as new old as old
for each row
begin
if nvl(:new.salary,0) >= 10000 then
raise_application_error (-20999,'Salary with
commissions should be less than 10000');
end if;
end;
/

Is This Answer Correct ?    15 Yes 0 No

Post New Answer

More SQL PLSQL Interview Questions

select top 3 sal from each dept?

17 Answers   IBM, TCS,


Can a trigger call a stored procedure?

0 Answers  


What is pl sql script?

0 Answers  


what is index? : Sql dba

0 Answers  


what is bdb (berkeleydb)? : Sql dba

0 Answers  


What are Nested Tables? How will u delete 5 rows from Nested Tables

3 Answers   IBM,


What is pseudo column ?

6 Answers   ABB,


Can we use distinct and group by together?

0 Answers  


what are pl/sql collections?

4 Answers   JPMorgan Chase, Oracle,


I want to display the employees who have joined in last two months. (It should be executed randomly means If I execute the query in March it should display Jan and Feb joined employees. Same query if i execute in Feb, 2007 it should display dec, 2006 and jan 2007 joined employees.

15 Answers   Wipro,


Explain what is an index?

0 Answers  


Explain what is a database?

0 Answers  


Categories