Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Insert multiple row's values if it not exists !!

2613150Feb 14 2014 — edited Feb 15 2014

Hello All ,

I have a question ,

If i have a table that contains 2 columns (ID , Status ) and the current info that is exists in this table is :

1     Open

2     Closed

3     Open

if for example a user will insert a row that have an ID, lets say 6 , how i can create a trigger that will insert the missing ID's , i.e. 4 , 5 with a status NONE if that ID's are not existed in the Column ID.Such that the inserted rows will be

4     NONE

5     NONE

Any idea !

Thank you in advance !

Regards,

This post has been answered by Baris Yildirim on Feb 15 2014
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 15 2014
Added on Feb 14 2014
15 comments
2,851 views