DBA Data[Home] [Help]

PACKAGE BODY: APPS.IEX_GAR_PUB

Source


1 PACKAGE BODY IEX_GAR_PUB AS
2 /* $Header: iextptwb.pls 120.7 2011/09/08 13:14:03 ehuh ship $ */
3 
4 ---------------------------------------------------------------------------
5 --    Start of Comments
6 ---------------------------------------------------------------------------
7 --    PACKAGE NAME:   IEX_GAR_PUB
8 --    ---------------------------------------------------------------------
9 --    PURPOSE
10 --
11 --      Main Package for the concurrent program
12 --      "Generate Access Records".
13 --
14 --      Procedures:
15 --         (see below for specification)
16 --
17 --    NOTES
18 --      This package to be called from the concurrent program
19 --		"Generate Access Records"
20 --
21 --    HISTORY
22 ---------------------------------------------------------------------------
23 
24 
25 /*-------------------------------------------------------------------------+
26  |                             PRIVATE CONSTANTS
27  +-------------------------------------------------------------------------*/
28   G_PKG_NAME  CONSTANT VARCHAR2(30):='IEX_GAR_PUB';
29   G_FILE_NAME CONSTANT VARCHAR2(12):='iextptwb.pls';
30   G_SORT_AREA_SIZE  CONSTANT NUMBER := 100000000;
31   G_HASH_AREA_SIZE  CONSTANT NUMBER := 100000000;
32   G_CURSOR_LIMIT    CONSTANT NUMBER := 10000;
33   -- for BES enhancement
34   G_BUSINESS_EVENT  CONSTANT VARCHAR2(60) := 'oracle.apps.as.tap.batch_mode';
35 
36 
37 /*-------------------------------------------------------------------------+
38  |                             PRIVATE DATATYPES
39  +-------------------------------------------------------------------------*/
40 
41 /*-------------------------------------------------------------------------*
42  |                             PRIVATE VARIABLES
43  *-------------------------------------------------------------------------*/
44   g_run_mode                      VARCHAR2(7);
45 
46 /*-------------------------------------------------------------------------*
47  |                             PRIVATE ROUTINES SPECIFICATION
48  *-------------------------------------------------------------------------*/
49 PROCEDURE Init(
50     p_run_mode        IN  VARCHAR2,
51     p_debug_mode      IN  VARCHAR2,
52     p_trace_mode      IN  VARCHAR2,
53     p_transaction_type     IN  VARCHAR2,
54     p_worker_id       IN  VARCHAR2,
55     p_actual_workers  IN  VARCHAR2,
56     p_prev_request_id IN  NUMBER,
57     p_seq_num         IN  NUMBER,
58     px_terr_globals  IN OUT NOCOPY IEX_TERR_WINNERS_PUB.TERR_GLOBALS);
59 FUNCTION exist_subscription(p_event_name IN VARCHAR2) return VARCHAR2;
60 PROCEDURE RAISE_BES(p_terr_globals IN OUT NOCOPY IEX_TERR_WINNERS_PUB.TERR_GLOBALS);
61 
62 
63 
64 /*------------------------------------------------------------------------*
65  |                              PUBLIC ROUTINES
66  *------------------------------------------------------------------------*/
67 
68 /*-------------------------------------------------------------------------*
69  | PUBLIC ROUTINE
70  |  Generate_Access_Records
71  |
72  | PURPOSE
73  |  The main procedure of the concurrent program
74  |
75  | NOTES
76  |
77  |
78  | HISTORY
79  *-------------------------------------------------------------------------*/
80 PROCEDURE Generate_Access_Records(
81     errbuf            OUT NOCOPY VARCHAR2,
82     retcode           OUT NOCOPY VARCHAR2,
83     p_run_mode        IN  VARCHAR2,
84     p_debug_mode      IN  VARCHAR2,
85     p_trace_mode      IN  VARCHAR2,
86     p_transaction_type IN  VARCHAR2,
87     p_worker_id       IN  VARCHAR2,
88     p_actual_workers  IN  VARCHAR2,
89     p_prev_request_id IN  NUMBER,
90     p_seq_num         IN  NUMBER,
91     p_assign_level     IN VARCHAR2)  -- Added for bug 8708291 pnaveenk multi level strategy
92 IS
93 l_terr_globals   IEX_TERR_WINNERS_PUB.TERR_GLOBALS;
94 l_status         BOOLEAN;
95 l_return_status  VARCHAR2(1);
96 l_msg_count      NUMBER;
97 l_msg_data       VARCHAR2(2000);
98 l_errbuf         VARCHAR2(4000);
99 l_retcode        VARCHAR2(255);
100 l_dyn_str        VARCHAR2(255);
101 l_temp           NUMBER;
102 l_sub_exist      VARCHAR2(1); -- to check where subscription exists
103 
104 -- ffang 110703, enh2737659, New new mode TAP
105 l_target_type    VARCHAR2(15) := '';
106 -- end ffang 110703, enh2737659
107 
108 l_wincount		NUMBER;
109 
110 l_percent_analysed   NUMBER;
111 l_acc_count          NUMBER;
112 l_org_id             NUMBER;
113 l_date_str           VARCHAR2(240);
114 
115 BEGIN
116 
117     g_debug_flag := p_debug_mode;
118     IEX_TERR_WINNERS_PUB.g_debug_flag := p_debug_mode;
119     BEGIN
120       SELECT  org_id INTO L_ORG_ID
121       FROM fnd_concurrent_requests
122       WHERE request_id=p_prev_request_id;
123     EXCEPTION WHEN OTHERS THEN
124      l_org_id := NULL;
125     END;
126 
127     IEX_TERR_WINNERS_PUB.Print_Debug('*** Starting  iextptwb.pls::Generate_Access_Records ***');
128     --Bug5043777. Fix By LKKUMAR. Start.
129     MO_GLOBAL.INIT('IEX');
130     IF (l_org_id IS NOT NULL) THEN
131         MO_GLOBAL.SET_POLICY_CONTEXT('S',l_org_id);
132     ELSE
133         MO_GLOBAL.SET_POLICY_CONTEXT('M',NULL);
134     END IF;
135 
136     IF (MO_GLOBAL.GET_CURRENT_ORG_ID IS NULL) THEN
137       IEX_TERR_WINNERS_PUB.Print_Debug('Operating Unit Set :  ' || 'All');
138     ELSE
139       IEX_TERR_WINNERS_PUB.Print_Debug('Operating Unit Set :  ' || MO_GLOBAL.GET_OU_NAME(MO_GLOBAL.GET_CURRENT_ORG_ID));
140     END IF;
141     --Bug5043777. Fix By LKKUMAR. End.
142 
143 
144     l_percent_analysed :=nvl(TO_NUMBER(fnd_profile.value('IEX_TAP_PERCENT_ANALYSED')),20);
145     IF p_run_mode = IEX_ATA_PUB.G_TOTAL_MODE THEN
146          l_target_type := 'TOTAL';
147     ELSIF p_run_mode = IEX_ATA_PUB.G_NEW_MODE THEN
148          l_target_type := 'INCREMENTAL';
149     END If;
150 
151 
152 -- Set the Global variables
153     Init(
154       p_run_mode,
155       p_debug_mode,
156       p_trace_mode,
157       p_transaction_type,
158       p_worker_id,
159       p_actual_workers,
160       p_prev_request_id,
161       p_seq_num,
162       l_terr_globals);
163 
164     COMMIT;
165 
166     --
167 
168     BEGIN
169 
170        IEX_TERR_WINNERS_PUB.Print_Debug('Starting JTY_ASSIGN_BULK_PUB.get_winners for worker '|| p_worker_id);
171 
172        select to_char( sysdate, 'DD-Mon-YYYY HH24:MI:SS') into l_date_str from dual;
173        FND_FILE.PUT_LINE(FND_FILE.LOG,'---' || l_date_str || '--------------------------');
174        FND_FILE.PUT_LINE(FND_FILE.LOG,'Starting JTY_ASSIGN_BULK_PUB.get_winners...');
175 
176         JTY_ASSIGN_BULK_PUB.get_winners(
177         p_api_version_number    => 1.0,
178         p_init_msg_list         => FND_API.G_FALSE,
179         p_source_id             => -1600,
180         p_trans_id              => -1601,
181         p_program_name          => 'COLLECTIONS/CUSTOMER PROGRAM',
182         p_mode                  => l_target_type,
183         p_percent_analyzed      => l_percent_analysed,
184         p_worker_id             => p_worker_id, -- the worker_id
185         x_return_status         => l_return_status,
186         x_msg_count             => l_msg_count,
187         x_msg_data              => l_msg_data,
188         ERRBUF                  => l_errbuf,
189         RETCODE                 => l_retcode
190         );
191 
192         IEX_TERR_WINNERS_PUB.Print_Debug('Completed JTY_ASSIGN_BULK_PUB.get_winners for worker '
193         || p_worker_id || ' with status ' || l_return_status);
194 
195 	IEX_TERR_WINNERS_PUB.Print_Debug('Message from JTY_ASSIGN_BULK_PUB.get_winners for worker ' ||
196 	l_msg_data);
197 
198         select to_char( sysdate, 'DD-Mon-YYYY HH24:MI:SS') into l_date_str from dual;
199         FND_FILE.PUT_LINE(FND_FILE.LOG,'---' || l_date_str || '--------------------------');
200         FND_FILE.PUT_LINE(FND_FILE.LOG,'Ending JTY_ASSIGN_BULK_PUB.get_winners...');
201 
202         COMMIT;
203 
204         EXCEPTION WHEN OTHERS THEN
205         IEX_TERR_WINNERS_PUB.Print_Debug('Error in JTY_ASSIGN_BULK_PUB.get_winners for worker '|| p_worker_id ||
206 	' '|| SQLERRM);
207         IEX_TERR_WINNERS_PUB.Print_Debug('Error buffer ' || l_errbuf);
208        END;
209 
210        SELECT count(*) INTO  l_acc_count FROM jtf_tae_1600_cust_winners;
211        IEX_TERR_WINNERS_PUB.Print_Debug('Number of records in jtf_tae_1600_cust_winners : ' || l_acc_count );
212 
213        FND_FILE.PUT_LINE(FND_FILE.LOG, 'Number of records in jtf_tae_1600_cust_winners : ' || l_acc_count );
214     --
215 
216 -- Set the Session parameters
217    IEX_ATA_PUB.Set_Area_Sizes;
218 
219 /*   Nothing is done for pre-cleaning.  kasreeni 4/20/2005 */
220 
221 -- Pre-cleaning of AS_ACCESSES_ALL and AS_TERRITORY_ACCESSES.
222    -- This is to be called if the Profile Option for Dup Res Deletion on address_id is enabled.
223     IF(l_terr_globals.enable_dups_rs_del = 'Y' ) THEN
224       IEX_TERR_ASSIGNMENT_CLEANUP.Cleanup_Duplicate_Resources(
225           x_errbuf        => l_errbuf,
226           x_retcode       => l_retcode,
227           p_terr_globals  => l_terr_globals);
228     END IF;
229 
230     IF l_terr_globals.transaction_type = 'ACCOUNT' THEN
231       IEX_PROCESS_ACCOUNT_WINNERS.Process_Account_Records(
232         x_errbuf        => l_errbuf,
233         x_retcode       => l_retcode,
234         p_terr_globals  => l_terr_globals,
235 	p_assignlevel =>  p_assign_level );  -- Changed for bug 8708291 pnaveenk multi level strategy
236     END IF;
237 
238 
239 
240 /*
241 -- Cleanup AS_TERRITORY_ACCESSES Records. Overload this procedure if LEAD Processing Goes Away.
242    -- Cleanup Terr Accesses for Lead, if the Lead Processing is Enabled-AS_DISABLE_BATCH_LEAD_TERR_ASSIGNMENT
243     IEX_TERR_ASSIGNMENT_CLEANUP.Cleanup_Terrritory_Accesses(
244           x_errbuf        => l_errbuf,
245           x_retcode       => l_retcode,
246           p_terr_globals  => l_terr_globals);
247 
248 -- Delete Unqualified Access Records for Account,Oppot,Lead.
249 IF l_terr_globals.transaction_type = 'ACCOUNT' THEN
250     -- ffang 110703, enh2737659, New new mode TAP
251     IEX_TERR_WINNERS_PUB.Print_Debug('Clean up for Accounts');
252     IF p_run_mode = IEX_ATA_PUB.G_TOTAL_MODE THEN
253         IEX_TERR_ASSIGNMENT_CLEANUP.Perform_Account_Cleanup(
254               x_errbuf        => l_errbuf,
255               x_retcode       => l_retcode,
256               p_terr_globals  => l_terr_globals);
257     END IF;
258     -- end ffang 110703, enh 2737659
259 
260     -- BES enhancement
261 
262 /**  Start Bug 4419234 07/08/2005  No business events for H release **/
263 /**
264      l_sub_exist := iex_gar_pub.exist_subscription(G_BUSINESS_EVENT);
265 
266      IF ((l_return_status = 'S')  AND (l_sub_exist = 'Y')) THEN
267 
268 		IEX_TERR_WINNERS_PUB.Print_Debug('--- Event subscription exists... ');
269 		IEX_TERR_WINNERS_PUB.Print_Debug('--- Event subscription raised from Account... ');
270 
271 		RAISE_BES(l_terr_globals);
272 
273 
274     END If;
275 **/
276 
277 /**  End Bug 4419234 07/08/2005  No business events for H release **/
278 
279 EXCEPTION
280 WHEN others THEN
281       IEX_TERR_WINNERS_PUB.Print_Debug('Exception: others in IEX_GAR_PUB::Generate_Access_Records');
282       IEX_TERR_WINNERS_PUB.Print_Debug('SQLCODE ' || to_char(SQLCODE) || ' SQLERRM ' || SQLERRM );
283       errbuf := SQLERRM;
284       retcode := SQLCODE;
285       --retcode := FND_API.G_RET_STS_UNEXP_ERROR;
286       l_status := FND_CONCURRENT.SET_COMPLETION_STATUS('ERROR', SQLERRM);
287 END Generate_Access_Records;
288 
289 /*-------------------------------------------------------------------------*
290  | PRIVATE ROUTINE
291  |  Init
292  |
293  | PURPOSE
294  |  Initialize the global session variables
295  |
296  | NOTES
297  |
298  | HISTORY
299  |
300  *-------------------------------------------------------------------------*/
301 
302 
303 PROCEDURE Init(
304     p_run_mode        IN  VARCHAR2,
305     p_debug_mode      IN  VARCHAR2,
306     p_trace_mode      IN  VARCHAR2,
307     p_transaction_type     IN  VARCHAR2,
308     p_worker_id       IN  VARCHAR2,
309     p_actual_workers  IN  VARCHAR2,
310     p_prev_request_id IN  NUMBER,
311     p_seq_num         IN  NUMBER,
312     px_terr_globals IN OUT NOCOPY IEX_TERR_WINNERS_PUB.TERR_GLOBALS)
313 IS
314     l_ata_request_id_of_failed_gar number := -1;
315     l_temp varchar(300) ;
316 
317 BEGIN
318 
319 
320 -- Set the Global variables
321 
322     px_terr_globals.debug_flag := p_debug_mode;
323     px_terr_globals.run_mode := p_run_mode;
324     px_terr_globals.transaction_type := p_transaction_type;
325     px_terr_globals.worker_id:=p_worker_id;
326 
327 
328 -- For Restart Mode, the prev_request_id is not the CURRENT ATA Request_id,
329 -- Rather it the request_id of the Failed GAR's ATA Request_id and so determine
330 -- the MODE and assign the value for px_terr_globals.prev_request_id accordingly.
331 -- Note: the Restart is applicable for the Failed GAR ONLY.
332     --px_terr_globals.prev_request_id := p_prev_request_id;
333 
334     px_terr_globals.sequence := p_seq_num;
335 
336     px_terr_globals.bulk_size:= nvl(to_number(fnd_profile.value('AS_BULK_COMMIT_SIZE')),10000);
337 
338     /*** Not needed now
339     if px_terr_globals.bulk_size < 10000 then
340      px_terr_globals.bulk_size:= 10000;
341     end if;
342     **/
343 
344     IF p_trace_mode = 'Y'
345     THEN
346         l_temp := 'alter session set events = ''10046 trace name context forever, level 8'' ';
347         EXECUTE IMMEDIATE l_temp;
348     END IF;
349 
350     begin
351       px_terr_globals.cursor_limit := nvl(to_number(fnd_profile.value('AS_TERR_RECORDS_TO_OPEN')) ,G_CURSOR_LIMIT);
352       if px_terr_globals.cursor_limit < 1 then
353          px_terr_globals.cursor_limit := G_CURSOR_LIMIT;
354       end if;
355     exception
356     when others then
357       px_terr_globals.cursor_limit := G_CURSOR_LIMIT;
358     end;
359 
360 
361     -- get profile option - USER_ID
362     px_terr_globals.user_id := to_number(fnd_profile.value('USER_ID'));
363 
364     px_terr_globals.prog_appl_id := FND_GLOBAL.PROG_APPL_ID;
365 
366     -- get profile option -- CONC_PROGRAM_ID
367     px_terr_globals.prog_id := to_number(fnd_profile.value('CONC_PROGRAM_ID'));
368 
369     -- get profile option -- CONC_LOGIN_ID
370     px_terr_globals.last_update_login := to_number(fnd_profile.value('CONC_LOGIN_ID'));
371 
372     -- get profile option -- CONC_REQUEST_ID
373     px_terr_globals.request_id := to_number(fnd_profile.value('CONC_REQUEST_ID'));
374 
375     -- If request_id = 0, select directly from sequence
376     IF px_terr_globals.request_id = 0 OR px_terr_globals.request_id IS NULL
377     THEN
378         -- Get concurrent sequence
379         IEX_TERR_WINNERS_PUB.Print_Debug('request_id is 0, get from sequence');
380         SELECT fnd_concurrent_requests_s.nextval into px_terr_globals.request_id from dual;
381     END IF;
382 
383     -- Get the profile option for AS_ENABLE_DUPS_RS_DELETION
384     -- OS: Enable Duplicate Resource Deletion
385     -- For Now this is asssumed to be 'Y'
386     px_terr_globals.enable_dups_rs_del := 'Y';
387     px_terr_globals.disable_lead_processing := FND_PROFILE.Value('AS_DISABLE_BATCH_LEAD_TERR_ASSIGNMENT') ;
388 
389     IF p_run_mode = 'RESTART' THEN
390        --Fetch the p_prev_request_id from JTF_TAE_1001_ACCOUNT_TRANS
391      begin
392        select REQUEST_ID into l_ata_request_id_of_failed_gar from jtf_tae_1001_account_trans
393        where request_id is not null and rownum < 2 ;
394      exception
395        when others then
396        IEX_TERR_WINNERS_PUB.Print_Debug('Cannot restart- JTF_TAE_1001_ACCOUNT_TRANS is Empty');
397        RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
398      end;
399      px_terr_globals.prev_request_id := l_ata_request_id_of_failed_gar;
400     ELSE
401        px_terr_globals.prev_request_id := p_prev_request_id;
402     END IF;
403 
404 
405 -- Print the Global variables
406 
407     COMMIT;
408 
409 EXCEPTION
410 WHEN others THEN
411       IEX_TERR_WINNERS_PUB.Print_Debug('Exception: others in AS_GAR_PUB::Init');
412       IEX_TERR_WINNERS_PUB.Print_Debug('SQLCODE ' || to_char(SQLCODE) ||
413                            ' SQLERRM ' || SQLERRM);
414       RAISE;
415 END Init;
416 
417 /*-------------------------------------------------------------------------*
418  | PRIVATE ROUTINE
419  |  exist_subscription
420  |
421  | PURPOSE
422  |  The purpose of this function is to check if a subscription exists for a
423  |  given event. Returns 'Y' if the subscription exist.
424  |
425  | NOTES
426  |
427  | HISTORY
428  *-------------------------------------------------------------------------*/
429 
430 FUNCTION exist_subscription(p_event_name IN VARCHAR2) RETURN VARCHAR2
431 
432 IS
433  --Bug4930397. Commented this as we don't have events now. Fix by LKKUMAR ON 10-JAN-2006. Start.
434  /*
435  CURSOR c1 IS
436  SELECT count(*)
437  FROM   wf_events eve,
438         wf_event_subscriptions sub
439  WHERE  eve.name = p_event_name
440  AND    eve.status = 'ENABLED'
441  AND    eve.guid = sub.event_filter_guid
442  AND    sub.status = 'ENABLED'
443  AND    sub.source_type = 'LOCAL';
444 
445 
446 l_count NUMBER;
447 l_yn  VARCHAR2(1);
448 
449 BEGIN
450 
451  open c1;
452 
453  fetch c1 into l_count;
454 
455  if l_count > 0 then
456  l_yn := 'Y';
457  end if;
458 
459  close c1;
460   RETURN l_yn;
461 */ --Bug4930397. Commented this as we don't have events now. Fix by LKKUMAR ON 10-JAN-2006. End.
462 
463 
464 BEGIN
465 
466 RETURN ('N');
467 /*Bug4930397. Function Should return a value So, returning 'N'. We Shall remove this once we have
468 decided to have events for terrirory assignment*/
469 
470 
471 END exist_subscription;
472 
473 /*-------------------------------------------------------------------------*
474  | PRIVATE ROUTINE
475  |  RAISE_BES
476  |
477  | PURPOSE
478  |  Raises the event
479  |
480  | NOTES
481  |
482  | HISTORY
483  *-------------------------------------------------------------------------*/
484 
485 PROCEDURE RAISE_BES(p_terr_globals IN OUT NOCOPY IEX_TERR_WINNERS_PUB.TERR_GLOBALS) IS
486 
487 l_mode                  VARCHAR2(7);
488 l_request_id            NUMBER;
489 l_ata_request_id        NUMBER;
490 l_worker_id             NUMBER;
491 l_transaction_type      VARCHAR2(30);
492 l_total_num_gar_workers NUMBER;
493 l_event_id              NUMBER;
494 x_errbuf                VARCHAR2(4000);
495 x_retcode               VARCHAR2(4000);
496 l_param_list            wf_parameter_list_t;
497 l_event_key             VARCHAR2(100);
498 l_msg                   VARCHAR2(4000);
499 
500 BEGIN
501 /**  Start Bug 4419234 07/08/2005  No business events for H release **/
502 /**  nullifying the code
503         l_mode := p_terr_globals.run_mode;
504         l_request_id := p_terr_globals.request_id;
505         l_ata_request_id := p_terr_globals.prev_request_id;
506         l_worker_id := p_terr_globals.worker_id;
507         l_transaction_type := p_terr_globals.transaction_type;
508 
509 	SELECT count(*) into l_total_num_gar_workers
510 	FROM   fnd_concurrent_requests
511 	WHERE  parent_request_id = l_ata_request_id;
512 
513 	 WF_EVENT.AddParameterToList(
514                 p_name => 'RUN_MODE',
515                 p_value => l_mode,
516                 p_parameterlist => l_param_list);
517 
518         WF_EVENT.AddParameterToList(
519                 p_name => 'REQUEST_ID',
520                 p_value => l_request_id,
521                 p_parameterlist => l_param_list);
522 
523         WF_EVENT.AddParameterToList(
524                 p_name => 'ATA_REQ_ID',
525                 p_value => l_ata_request_id,
526                 p_parameterlist => l_param_list);
527 
528         WF_EVENT.AddParameterToList(
529                 p_name => 'WORKER_ID',
530                 p_value => l_worker_id,
531                 p_parameterlist => l_param_list);
532 
533         WF_EVENT.AddParameterToList(
534                 p_name => 'TRANS_TYPE',
535                 p_value => l_transaction_type,
536  		p_parameterlist => l_param_list);
537 
538         WF_EVENT.AddParameterToList(
539                 p_name => 'TOTAL_WORKERS',
540                 p_value => l_total_num_gar_workers,
541                 p_parameterlist => l_param_list);
542 
543 	     begin
544 
545                 SELECT AS_BUSINESS_EVENT_S.nextval INTO l_event_id FROM dual;
546 
547         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- CALL WF_EVENT.RAISE.Start...');
548         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- l_event_id = '||l_event_id);
549         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- l_mode = '||l_mode);
550         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- l_request_id = '||l_request_id);
551         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- l_ata_request_id = '||l_ata_request_id);
552         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- l_worker_id = '||l_worker_id);
553         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- l_transaction_type = '||l_transaction_type);
554         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- l_total_num_gar_workers = '||l_total_num_gar_workers);
555 
556 
557         	wf_event.raise (
558                 	p_event_name => G_BUSINESS_EVENT,
559                 	p_event_key => l_event_id,
560                 	p_parameters => l_param_list);
561 
562         	EXCEPTION
563 
564                 WHEN others THEN
565 
566                         x_errbuf := SQLERRM;
567                         x_retcode := SQLCODE;
568 
569         	IEX_TERR_WINNERS_PUB.Print_Debug(' --- x_errbuf = '||x_errbuf||' , x_retcode = '||x_retcode);
570 
571 		end;
572 
573 	l_param_list.DELETE;
574 	IEX_TERR_WINNERS_PUB.Print_Debug(' --- CALL WF_EVENT.RAISE.End...');
575 
576   **/
577 
578   null;
579 
580 /**  End  Bug 4419234 07/08/2005  No business events for H release **/
581 
582 END RAISE_BES;
583 
584 END IEX_GAR_PUB;