I working an Alert that notifies Learners as they are place on "The Waiting List" if the class is full. However, my user wants the notification to be executed as Learners are placed on the waiting list. In that case, when the OTA-BOOKING_STATUS_TYPES changes the update occur. How can I create a trigger doing so or do have any other options? Please help.
Here is my query:
Select ppf.first_name ||' '||ppf.last_name as person_name
from per_people_f ppf
, ota_delegate_bookings odb
, ota_booking_status_types obst
, ota_events oe
where odb.delegate_person_id = ppf.person_id
and trunc(odb.last_update_date) = trunc(sysdate)
and odb.booking_status_type_id = obst.booking_status_type_id
and oe.event_id = odb.event_id
and odb.booking_status_type_id = '11'
and obst.name = 'On Waiting List'
and TRUNC(SYSDATE) BETWEEN ppf.effective_start_date AND ppf.effective_end_date