| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.server -> Trigger(?) question
Hello experts,
I've got a problem with creating a trigger, or maybe it would be better to solve the problem on another way(?). If somebody could give it a go, I would really appreciate the help;
On a certain table there are the next columns:
PRODUCT_ID(PK) STATUS OLD_PRODUCT_ID
---------- -------- --------------
1 INACTIVE 254
2 INACTIVE 259
3 ACTIVE 280 *
4 INACTIVE 312
5 INACTIVE 280 *
6 ACTIVE 129
When a status is set from INACTIVE to ACTIVE, there
must be a check (trigger?) to see if the value in OLD_PRODUCT_ID
is unique in the column OLD_PRODUCT_ID.
For example the rows indicated with *. So the trigger must
go off afther changing the status in row 5 to ACTIVE.
I think this shouldn't be too difficult, but one way or another, I can't get it too work!
Any help is appreciated, preferred by mail. Thanks in advance!
Regards,
Erik
Received on Fri Jan 09 1998 - 00:00:00 CST
![]() |
![]() |