Schema: ASSIGNMENT (ticket number, tech pplSoft, date assigned, status)
Where status eld is an enumeration, could be: assigned, in progress, delegated, closed successful, or closed unsuccessful
1) Write a trigger called ClosedTicket that whenever the status attribute
of the ASSIGNMENT table is changed to ‘closed successful’, or to ‘closed unsuccessful’,
it sets the value of the date closed attribute of the TICKETS table to the current
date.
Do i start this like this? and in the where clause use status = ‘closed successful’ OR status = ‘closed unsuccessful’ ?
CREATE OR REPLACE TRIGGER ClosedTicket
after update on
Something like this should work (though I’m guessing what the name of the primary key column in
TICKETSis).