Sample Code :
PROCEDURE SEND_WF_NOTIFICATION(I_TO IN VARCHAR2,
I_SUBJECT IN VARCHAR2,
I_TEXT IN VARCHAR2)
IS
/*
I_TO : Oracle EBS帳號
I_SUBJECT : 要顯示在Worklist的主旨
I_TEXT : 內容
*/
V_NOTIFICATION_ID NUMBER;
--
PRAGMA AUTONOMOUS_TRANSACTION;
BEGIN
V_NOTIFICATION_ID := WF_NOTIFICATION.SEND(ROLE => I_TO,
MSG_TYPE => 'CS_MSGS',
MSG_NAME => 'FYI_MESSAGE',
PRIORITY => 1);
WF_NOTIFICATION.SETATTRTEXT(NID => V_NOTIFICATION_ID,
ANAME => 'OBJECT_TYPE',
AVALUE => I_SUBJECT);
WF_NOTIFICATION.SETATTRTEXT(NID => V_NOTIFICATION_ID,
ANAME => 'MESSAGE_TEXT',
AVALUE => I_TEXT); --MESSAGE BODY
COMMIT;
END;