sales persons should always receive commission of 100 at
least. employees who r not sales persons should never
receive commission.(Triggers)



sales persons should always receive commission of 100 at least. employees who r not sales persons ..

Answer / narenkumar reddy

create or replace
trigger trigger_name
before update on emp
for each row
begin
if job<>'salesman' then
raise_application_error(-20001,'should never receive the
commission')
end if;
end;

Is This Answer Correct ?    6 Yes 13 No

Post New Answer

More SQL PLSQL Interview Questions

Which nosql database is best?

0 Answers  


How many postgresql users are there, worldwide?

0 Answers  


why we use nocopy?

2 Answers   Polaris,


what is meant by urlencode and urldocode? : Sql dba

0 Answers  


what is pragma ?

1 Answers   Polaris,






Does truncate remove indexes?

0 Answers  


How do you exit in sql?

0 Answers  


What is the difference between distinct and unique in sql?

0 Answers  


What are the syntax and use of the coalesce function?

0 Answers  


What is graph sql?

0 Answers  


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

8 Answers   iFlex,


What is set serveroutput on?

0 Answers  


Categories