19:
20: begin
21: select upper(queue_name), upper(name)
22: into x_queue_name, x_agent_name
23: from wf_agents
24: where guid = p_agent_guid;
25:
26: if (wf_log_pkg.level_procedure >= fnd_log.g_current_runtime_level) then
27: wf_log_pkg.string(wf_log_pkg.level_procedure,
172: --Cursor to select the to_agents for the recipient list
173: CURSOR recipients(agent_name varchar2,system_name varchar2) is
174: select agt2.name ,agt2.address, agt2.protocol, agt2.queue_name
175: from wf_agent_groups agp ,
176: wf_agents agt1 ,
177: wf_agents agt2 ,
178: wf_systems sys
179: where agt1.name = agent_name
180: and agp.group_guid = agt1.guid
173: CURSOR recipients(agent_name varchar2,system_name varchar2) is
174: select agt2.name ,agt2.address, agt2.protocol, agt2.queue_name
175: from wf_agent_groups agp ,
176: wf_agents agt1 ,
177: wf_agents agt2 ,
178: wf_systems sys
179: where agt1.name = agent_name
180: and agp.group_guid = agt1.guid
181: and agt1.type = 'GROUP'
197: end if;
198:
199: -- Get Out Agent details --
200: select agt.queue_name into x_out_queue
201: from wf_agents agt,
202: wf_systems sys
203: where agt.name = x_out_agent_name
204: and sys.name = x_out_system_name
205: and sys.guid = agt.system_guid;