Oracle Workflow API Reference Release 2.6.3.5 Part Number B12163-02 |
Previous | Next | Contents | Index | Glossary |
Attention: You must call the Initialize method before you can perform any further manipulation on a new WF_EVENT_T object.
declare
l_overrideagent varchar2(30) := '&overrideagent';
l_overridesystem varchar2(30) := '&overridesystem';
l_fromagent varchar2(30) := '&fromagent';
l_fromsystem varchar2(30) := '&fromsystem';
l_toagent varchar2(30) := '&toagent';
l_tosystem varchar2(30) := '&tosystem';
l_eventname varchar2(100) := '&eventname';
l_eventkey varchar2(100) := '&eventkey';
l_msg varchar2(200) := '&message';
l_clob clob;
l_overrideagent_t wf_agent_t;
l_toagent_t wf_agent_t;
l_fromagent_t wf_agent_t;
l_event_t wf_event_t;
begin
/*You must call wf_event_t.initialize before you can manipulate
a new wf_event_t object.*/
wf_event_t.initialize(l_event_t);
l_overrideagent_t := wf_agent_t(l_overrideagent,
l_overridesystem);
l_toagent_t := wf_agent_t(l_toagent, l_tosystem);
l_fromagent_t := wf_agent_t(l_fromagent, l_fromsystem);
if l_msg is null then
l_event_t.Content(l_eventname, l_eventkey, null);
else
dbms_lob.createtemporary(l_clob, FALSE, DBMS_LOB.CALL);
dbms_lob.write(l_clob, length(l_msg), 1, l_msg);
l_event_t.Content(l_eventname, l_eventkey, l_clob);
end if;
l_event_t.Address(l_fromagent_t, l_toagent_t, 50, sysdate);
wf_event.enqueue(l_event_t, l_overrideagent_t);
end;
Previous | Next | Contents | Index | Glossary |