Create trigger [message #281573] |
Sun, 18 November 2007 07:49 |
malli.sql
Messages: 1 Registered: October 2007 Location: Pune
|
Junior Member |
|
|
Hi ALL,
I have assigned the task given below.please guide me in approaching the solution.Help will be highly appreciated.
Thanks& Regards
XYZ
Step1:
Create a table emp1 with columns eid datatype number,ename datatype charecter constraints primary key on eid.
Step2:
Create sequence to generate the eid which start with 1000 and increase with 1
Step3:
Create procedure and insert the eid(get the value from sequence) and ename as a constant
e.g mallikarjun
Step4:
Create trigger (before insert) on emp1 table wich will call the another procedure(in Step:5)
Step5:
create procedure which is having in out parameter as type emp1.ename
display the ename before inserting
change the ename to mallikarjun kotturu
display the ename after insert.
The final data should be 1000 as eid and mallikarju kotturu as ename in the table.
|
|
|
|
|