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 ?

Answer Posted / 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       View All Answers


Please Help Members By Posting Answers For Below Questions

what are the security recommendations while using mysql? : Sql dba

1174


Is it possible to remove child records without removing master table records...the two having pk,fk relationship?

1300


is mysql query is case sensitive? : Sql dba

1159


What is a trigger word?

1073


How would you reference column values before and after you have inserted and deleted triggers?

1113


how to shut down the server with 'mysqladmin'? : Sql dba

1046


Which table is left in join?

1015


Why is sql better than hql?

1061


How does a covering index work?

1008


Give the order of sql select?

1180


Explain foreign key in sql?

1078


What is a relationship and what are they?

1225


Inline the values in PL/SQL, what does it mean.?

1271


what is a join? : Sql dba

1083


What is the difference between microsoft access and sql server?

1104