DBA Data[Home] [Help]

PACKAGE BODY: APPS.IEC_SCHEDULE_MGMT_PUB

Source


1 PACKAGE BODY IEC_SCHEDULE_MGMT_PUB AS
2 /* $Header: IECSCHMB.pls 120.1 2006/03/28 09:28:27 hhuang noship $ */
3 
4 G_PKG_NAME CONSTANT VARCHAR2(30) := 'IEC_SCHEDULE_MGMT_PUB';
5 
6 PROCEDURE CopyScheduleEntries
7    ( p_api_version IN NUMBER,
8      p_init_msg_list IN VARCHAR2,
9      p_commit IN VARCHAR2,
10      p_resp_appl_id IN NUMBER,
11      p_resp_id IN NUMBER,
12      p_user_id IN NUMBER,
13      p_login_id IN NUMBER,
14      x_return_status IN OUT NOCOPY VARCHAR2,
15      x_msg_count IN OUT NOCOPY NUMBER,
16      x_msg_data IN OUT NOCOPY VARCHAR2,
17      p_src_schedule_id  IN NUMBER,
18      p_dest_schedule_id IN NUMBER
19 ) AS
20         l_api_name              CONSTANT VARCHAR2(30) := 'CopyScheduleEntries';
21         l_api_version           CONSTANT NUMBER       := 1.0;
22         l_api_name_full         CONSTANT VARCHAR2(61) := g_pkg_name||'.'||l_api_name;
23         l_return_status         VARCHAR2(1);
24         l_return_code           VARCHAR2(1);
25         l_data                  VARCHAR2(100);
26         l_count                 NUMBER;
27         l_src_schedule_id       NUMBER(15);
28         l_dest_schedule_id      NUMBER(15);
29 BEGIN
30 
31    SAVEPOINT copy_schedule_entries_pub;
32 
33    -- Preprocessing Call
34    l_src_schedule_id := p_src_schedule_id;
35    l_dest_schedule_id := p_dest_schedule_id;
36 
37    IEC_SCHEDULE_MGMT_VUHK.CopyScheduleEntries_pre
38       ( p_src_schedule_id => l_src_schedule_id
39       , p_dest_schedule_id => l_dest_schedule_id
40       , x_data => l_data
41       , x_count => l_count
42       , x_return_code => l_return_code);
43 
44    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
45       RAISE FND_API.G_EXC_ERROR;
46    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
47       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
48    END IF;
49 
50    -- Standard call to check for call compatibility
51    IF NOT fnd_api.compatible_api_call( l_api_version
52                                      , p_api_version
53                                      , l_api_name
54                                      , g_pkg_name) THEN
55       RAISE fnd_api.g_exc_unexpected_error;
56    END IF;
57 
58    -- Initialize message list if p_init_msg_list is set to TRUE
59    IF fnd_api.to_boolean(p_init_msg_list) THEN
60       fnd_msg_pub.initialize;
61    END IF;
62 
63    -- Initialize API return status to success
64    x_return_status := fnd_api.g_ret_sts_success;
65 
66    --
67    -- Validate user and login session IDs
68    --
69    IF (p_user_id IS NULL) THEN
70       IEC_SCHEDULE_MGMT_UTIL_PVT.add_null_parameter_msg(l_api_name_full, 'p_user_id');
71       RAISE fnd_api.g_exc_error;
72    ELSE
73       IEC_SCHEDULE_MGMT_UTIL_PVT.validate_who_info
74         ( p_api_name           => l_api_name_full
75          , p_parameter_name_usr => 'p_user_id'
76          , p_parameter_name_log => 'p_login_id'
77          , p_user_id            => p_user_id
78          , p_login_id           => p_login_id
79          , x_return_status      => l_return_status);
80 
81       IF (l_return_status <> fnd_api.g_ret_sts_success) THEN
82          RAISE fnd_api.g_exc_error;
83       END IF;
84    END IF;
85 
86 ---------------------------------------------------------------------
87 
88    -- DO ACTUAL WORK HERE BY CALLING PRIVATE METHOD
89 
90    IEC_VALIDATE_PVT.Copy_ScheduleEntries_Pub
91       ( p_src_schedule_id => l_src_schedule_id
92       , p_dest_schedule_id => l_dest_schedule_id
93       , p_commit => FALSE
94       , x_return_status => l_return_code);
95 
96    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
97       RAISE FND_API.G_EXC_ERROR;
98    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
99       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
100    END IF;
101 
102 ---------------------------------------------------------------------
103 
104    -- Post processing Call
105    IEC_SCHEDULE_MGMT_VUHK.CopyScheduleEntries_post
106       ( p_src_schedule_id => l_src_schedule_id
107       , p_dest_schedule_id => l_dest_schedule_id
108       , x_data => l_data
109       , x_count => l_count
110       , x_return_code => l_return_code);
111 
112    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
113       RAISE FND_API.G_EXC_ERROR;
114    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
115       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
116    END IF;
117 
118    IF fnd_api.to_boolean(p_commit) THEN
119       COMMIT WORK;
120    END IF;
121 
122    -- Standard call to get message count and if count is 1, get message info
123    fnd_msg_pub.count_and_get( p_count  => x_msg_count
124                             , p_data   => x_msg_data );
125 
126 EXCEPTION
127    WHEN fnd_api.g_exc_error THEN
128       ROLLBACK TO copy_schedule_entries_pub;
129       x_return_status := fnd_api.g_ret_sts_error;
130       fnd_msg_pub.count_and_get( p_count => x_msg_count
131                                , p_data  => x_msg_data );
132    WHEN fnd_api.g_exc_unexpected_error THEN
133       ROLLBACK TO copy_schedule_entries_pub;
134       x_return_status := fnd_api.g_ret_sts_unexp_error;
135       fnd_msg_pub.count_and_get( p_count => x_msg_count
136                                , p_data  => x_msg_data );
137    WHEN OTHERS THEN
138       ROLLBACK TO copy_schedule_entries_pub;
139       x_return_status := fnd_api.g_ret_sts_unexp_error;
140       IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
141          fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
142       END IF;
143       fnd_msg_pub.count_and_get( p_count => x_msg_count
144                                , p_data  => x_msg_data );
145 
146 END CopyScheduleEntries;
147 
148 PROCEDURE MoveScheduleEntries
149    ( p_api_version IN NUMBER,
150      p_init_msg_list IN VARCHAR2,
151      p_commit IN VARCHAR2,
152      p_resp_appl_id IN NUMBER,
153      p_resp_id IN NUMBER,
154      p_user_id IN NUMBER,
155      p_login_id IN NUMBER,
156      x_return_status IN OUT NOCOPY VARCHAR2,
157      x_msg_count IN OUT NOCOPY NUMBER,
158      x_msg_data IN OUT NOCOPY VARCHAR2,
159      p_src_schedule_id  IN NUMBER,
160      p_dest_schedule_id IN NUMBER
161 ) AS
162         l_api_name              CONSTANT VARCHAR2(30) := 'MoveScheduleEntries';
163         l_api_version           CONSTANT NUMBER       := 1.0;
164         l_api_name_full         CONSTANT VARCHAR2(61) := g_pkg_name||'.'||l_api_name;
165         l_return_status         VARCHAR2(1);
166         l_return_code           VARCHAR2(1);
167         l_data                  VARCHAR2(100);
168         l_count                 NUMBER;
169         l_src_schedule_id       NUMBER(15);
170         l_dest_schedule_id      NUMBER(15);
171 BEGIN
172 
173    SAVEPOINT copy_schedule_entries_pub;
174 
175    -- Preprocessing Call
176    l_src_schedule_id := p_src_schedule_id;
177    l_dest_schedule_id := p_dest_schedule_id;
178 
179    IEC_SCHEDULE_MGMT_VUHK.MoveScheduleEntries_pre
180       ( p_src_schedule_id => l_src_schedule_id
181       , p_dest_schedule_id => l_dest_schedule_id
182       , x_data => l_data
183       , x_count => l_count
184       , x_return_code => l_return_code);
185 
186    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
187       RAISE FND_API.G_EXC_ERROR;
188    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
189       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
190    END IF;
191 
192    -- Standard call to check for call compatibility
193    IF NOT fnd_api.compatible_api_call( l_api_version
194                                      , p_api_version
195                                      , l_api_name
196                                      , g_pkg_name) THEN
197       RAISE fnd_api.g_exc_unexpected_error;
198    END IF;
199 
200    -- Initialize message list if p_init_msg_list is set to TRUE
201    IF fnd_api.to_boolean(p_init_msg_list) THEN
202       fnd_msg_pub.initialize;
203    END IF;
204 
205    -- Initialize API return status to success
206    x_return_status := fnd_api.g_ret_sts_success;
207 
208    --
209    -- Validate user and login session IDs
210    --
211    IF (p_user_id IS NULL) THEN
212       IEC_SCHEDULE_MGMT_UTIL_PVT.add_null_parameter_msg(l_api_name_full, 'p_user_id');
213       RAISE fnd_api.g_exc_error;
214    ELSE
215       IEC_SCHEDULE_MGMT_UTIL_PVT.validate_who_info
216         ( p_api_name           => l_api_name_full
217          , p_parameter_name_usr => 'p_user_id'
218          , p_parameter_name_log => 'p_login_id'
219          , p_user_id            => p_user_id
220          , p_login_id           => p_login_id
221          , x_return_status      => l_return_status);
222 
223       IF (l_return_status <> fnd_api.g_ret_sts_success) THEN
224          RAISE fnd_api.g_exc_error;
225       END IF;
226    END IF;
227 
228 ---------------------------------------------------------------------
229 
230    -- DO ACTUAL WORK HERE BY CALLING PRIVATE METHOD
231 
232    IEC_VALIDATE_PVT.Move_ScheduleEntries_Pub
233       ( p_src_schedule_id => l_src_schedule_id
234       , p_dest_schedule_id => l_dest_schedule_id
235       , p_commit => FALSE
236       , x_return_status => l_return_code);
237 
238    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
239       RAISE FND_API.G_EXC_ERROR;
240    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
241       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
242    END IF;
243 
244 ---------------------------------------------------------------------
245 
246    -- Post processing Call
247    IEC_SCHEDULE_MGMT_VUHK.MoveScheduleEntries_post
248       ( p_src_schedule_id => l_src_schedule_id
249       , p_dest_schedule_id => l_dest_schedule_id
250       , x_data => l_data
251       , x_count => l_count
252       , x_return_code => l_return_code);
253 
254    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
255       RAISE FND_API.G_EXC_ERROR;
256    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
257       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
258    END IF;
259 
260    IF fnd_api.to_boolean(p_commit) THEN
261       COMMIT WORK;
262    END IF;
263 
264    -- Standard call to get message count and if count is 1, get message info
265    fnd_msg_pub.count_and_get( p_count  => x_msg_count
266                             , p_data   => x_msg_data );
267 
268 EXCEPTION
269    WHEN fnd_api.g_exc_error THEN
270       ROLLBACK TO move_schedule_entries_pub;
271       x_return_status := fnd_api.g_ret_sts_error;
272       fnd_msg_pub.count_and_get( p_count => x_msg_count
273                                , p_data  => x_msg_data );
274    WHEN fnd_api.g_exc_unexpected_error THEN
275       ROLLBACK TO move_schedule_entries_pub;
276       x_return_status := fnd_api.g_ret_sts_unexp_error;
277       fnd_msg_pub.count_and_get( p_count => x_msg_count
278                                , p_data  => x_msg_data );
279    WHEN OTHERS THEN
280       ROLLBACK TO move_schedule_entries_pub;
281       x_return_status := fnd_api.g_ret_sts_unexp_error;
282       IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
283          fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
284       END IF;
285       fnd_msg_pub.count_and_get( p_count => x_msg_count
286                                , p_data  => x_msg_data );
287 
288 END MoveScheduleEntries;
289 
290 PROCEDURE PurgeScheduleEntries
291    ( p_api_version IN NUMBER,
292      p_init_msg_list IN VARCHAR2,
293      p_commit IN VARCHAR2,
294      p_resp_appl_id IN NUMBER,
295      p_resp_id IN NUMBER,
296      p_user_id IN NUMBER,
297      p_login_id IN NUMBER,
298      x_return_status IN OUT NOCOPY VARCHAR2,
299      x_msg_count IN OUT NOCOPY NUMBER,
300      x_msg_data IN OUT NOCOPY VARCHAR2,
301      p_schedule_id  IN NUMBER
302 ) AS
303         l_api_name              CONSTANT VARCHAR2(30) := 'PurgeScheduleEntries';
304         l_api_version           CONSTANT NUMBER       := 1.0;
305         l_api_name_full         CONSTANT VARCHAR2(61) := g_pkg_name||'.'||l_api_name;
306         l_return_status         VARCHAR2(1);
307         l_return_code           VARCHAR2(1);
308         l_data                  VARCHAR2(100);
309         l_count                 NUMBER;
310         l_schedule_id           NUMBER(15);
311 
312 BEGIN
313 
314    SAVEPOINT purge_schedule_entries_pub;
315 
316    -- Preprocessing Call
317    l_schedule_id := p_schedule_id;
318 
319    IEC_SCHEDULE_MGMT_VUHK.PurgeScheduleEntries_pre
320       ( p_schedule_id => l_schedule_id
321       , x_data => l_data
322       , x_count => l_count
323       , x_return_code => l_return_code);
324 
325    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
326       RAISE FND_API.G_EXC_ERROR;
327    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
328       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
329    END IF;
330 
331    -- Standard call to check for call compatibility
332    IF NOT fnd_api.compatible_api_call( l_api_version
333                                      , p_api_version
334                                      , l_api_name
335                                      , g_pkg_name) THEN
336       RAISE fnd_api.g_exc_unexpected_error;
337    END IF;
338 
339    -- Initialize message list if p_init_msg_list is set to TRUE
340    IF fnd_api.to_boolean(p_init_msg_list) THEN
341       fnd_msg_pub.initialize;
342    END IF;
343 
344    -- Initialize API return status to success
345    x_return_status := fnd_api.g_ret_sts_success;
346 
347    --
348    -- Validate user and login session IDs
349    --
350    IF (p_user_id IS NULL) THEN
351       IEC_SCHEDULE_MGMT_UTIL_PVT.add_null_parameter_msg(l_api_name_full, 'p_user_id');
352       RAISE fnd_api.g_exc_error;
353    ELSE
354       IEC_SCHEDULE_MGMT_UTIL_PVT.validate_who_info
355         ( p_api_name           => l_api_name_full
356          , p_parameter_name_usr => 'p_user_id'
357          , p_parameter_name_log => 'p_login_id'
358          , p_user_id            => p_user_id
359          , p_login_id           => p_login_id
360          , x_return_status      => l_return_status);
361 
362       IF (l_return_status <> fnd_api.g_ret_sts_success) THEN
363          RAISE fnd_api.g_exc_error;
364       END IF;
365    END IF;
366 
367 ---------------------------------------------------------------------
368 
369    -- DO ACTUAL WORK HERE BY CALLING PRIVATE METHOD
370 
371    IEC_VALIDATE_PVT.Purge_ScheduleEntries_Pub
372       ( p_schedule_id => l_schedule_id
373       , p_commit => FALSE
374       , x_return_status => l_return_code);
375 
376    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
377       RAISE FND_API.G_EXC_ERROR;
378    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
379       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
380    END IF;
381 
382 ---------------------------------------------------------------------
383 
384    -- Post processing Call
385    IEC_SCHEDULE_MGMT_VUHK.PurgeScheduleEntries_post
386       ( p_schedule_id => l_schedule_id
387       , x_data => l_data
388       , x_count => l_count
389       , x_return_code => l_return_code);
390 
391    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
392       RAISE FND_API.G_EXC_ERROR;
393    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
394       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
395    END IF;
396 
397    IF fnd_api.to_boolean(p_commit) THEN
398       COMMIT WORK;
399    END IF;
400 
401    -- Standard call to get message count and if count is 1, get message info
402    fnd_msg_pub.count_and_get( p_count  => x_msg_count
403                             , p_data   => x_msg_data );
404 
405 EXCEPTION
406    WHEN fnd_api.g_exc_error THEN
407       ROLLBACK TO purge_schedule_entries_pub;
408       x_return_status := fnd_api.g_ret_sts_error;
409       fnd_msg_pub.count_and_get( p_count => x_msg_count
410                                , p_data  => x_msg_data );
411    WHEN fnd_api.g_exc_unexpected_error THEN
412       ROLLBACK TO purge_schedule_entries_pub;
413       x_return_status := fnd_api.g_ret_sts_unexp_error;
414       fnd_msg_pub.count_and_get( p_count => x_msg_count
415                                , p_data  => x_msg_data );
416    WHEN OTHERS THEN
417       ROLLBACK TO purge_schedule_entries_pub;
418       x_return_status := fnd_api.g_ret_sts_unexp_error;
419       IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
420          fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
421       END IF;
422       fnd_msg_pub.count_and_get( p_count => x_msg_count
423                                , p_data  => x_msg_data );
424 
425 END PurgeScheduleEntries;
426 
427 PROCEDURE StopScheduleExecution
428    ( p_api_version IN NUMBER,
429      p_init_msg_list IN VARCHAR2,
430      p_commit IN VARCHAR2,
431      p_resp_appl_id IN NUMBER,
432      p_resp_id IN NUMBER,
433      p_user_id IN NUMBER,
434      p_login_id IN NUMBER,
435      x_return_status IN OUT NOCOPY VARCHAR2,
436      x_msg_count IN OUT NOCOPY NUMBER,
437      x_msg_data IN OUT NOCOPY VARCHAR2,
438      p_schedule_id  IN NUMBER
439 ) AS
440         l_api_name              CONSTANT VARCHAR2(30) := 'StopScheduleExecution';
441         l_api_version           CONSTANT NUMBER       := 1.0;
442         l_api_name_full         CONSTANT VARCHAR2(61) := g_pkg_name||'.'||l_api_name;
443         l_return_status         VARCHAR2(1);
444         l_return_code           VARCHAR2(1);
445         l_data                  VARCHAR2(100);
446         l_count                 NUMBER;
447         l_schedule_id           NUMBER(15);
448 
449 BEGIN
450 
451    SAVEPOINT stop_schedule_pub;
452 
453    -- Preprocessing Call
454    l_schedule_id := p_schedule_id;
455 
456    IEC_SCHEDULE_MGMT_VUHK.StopScheduleExecution_pre
457       ( p_schedule_id => l_schedule_id
458       , x_data => l_data
459       , x_count => l_count
460       , x_return_code => l_return_code);
461 
462    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
463       RAISE FND_API.G_EXC_ERROR;
464    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
465       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
466    END IF;
467 
468    -- Standard call to check for call compatibility
469    IF NOT fnd_api.compatible_api_call( l_api_version
470                                      , p_api_version
471                                      , l_api_name
472                                      , g_pkg_name) THEN
473       RAISE fnd_api.g_exc_unexpected_error;
474    END IF;
475 
476    -- Initialize message list if p_init_msg_list is set to TRUE
477    IF fnd_api.to_boolean(p_init_msg_list) THEN
478       fnd_msg_pub.initialize;
479    END IF;
480 
481    -- Initialize API return status to success
482    x_return_status := fnd_api.g_ret_sts_success;
483 
484    --
485    -- Validate user and login session IDs
486    --
487    IF (p_user_id IS NULL) THEN
488       IEC_SCHEDULE_MGMT_UTIL_PVT.add_null_parameter_msg(l_api_name_full, 'p_user_id');
489       RAISE fnd_api.g_exc_error;
490    ELSE
491       IEC_SCHEDULE_MGMT_UTIL_PVT.validate_who_info
492         ( p_api_name           => l_api_name_full
493          , p_parameter_name_usr => 'p_user_id'
494          , p_parameter_name_log => 'p_login_id'
495          , p_user_id            => p_user_id
496          , p_login_id           => p_login_id
497          , x_return_status      => l_return_status);
498 
499       IF (l_return_status <> fnd_api.g_ret_sts_success) THEN
500          RAISE fnd_api.g_exc_error;
501       END IF;
502    END IF;
503 
504 ---------------------------------------------------------------------
505 
506    -- DO ACTUAL WORK HERE BY CALLING PRIVATE METHOD
507 
508    IEC_STATUS_PVT.Stop_ScheduleExecution_Pub
509       ( p_schedule_id => l_schedule_id
510       , p_commit => FALSE
511       , x_return_status => l_return_code);
512 
513    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
514       RAISE FND_API.G_EXC_ERROR;
515    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
516       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
517    END IF;
518 
519 ---------------------------------------------------------------------
520 
521    -- Post processing Call
522    IEC_SCHEDULE_MGMT_VUHK.StopScheduleExecution_post
523       ( p_schedule_id => l_schedule_id
524       , x_data => l_data
525       , x_count => l_count
526       , x_return_code => l_return_code);
527 
528    IF (l_return_code = FND_API.G_RET_STS_ERROR) THEN
529       RAISE FND_API.G_EXC_ERROR;
530    ELSIF (l_return_code = FND_API.G_RET_STS_UNEXP_ERROR) THEN
531       RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
532    END IF;
533 
534    IF fnd_api.to_boolean(p_commit) THEN
535       COMMIT WORK;
536    END IF;
537 
538    -- Standard call to get message count and if count is 1, get message info
539    fnd_msg_pub.count_and_get( p_count  => x_msg_count
540                             , p_data   => x_msg_data );
541 
542 EXCEPTION
543    WHEN fnd_api.g_exc_error THEN
544       ROLLBACK TO stop_schedule_pub;
545       x_return_status := fnd_api.g_ret_sts_error;
546       fnd_msg_pub.count_and_get( p_count => x_msg_count
547                                , p_data  => x_msg_data );
548    WHEN fnd_api.g_exc_unexpected_error THEN
549       ROLLBACK TO stop_schedule_pub;
550       x_return_status := fnd_api.g_ret_sts_unexp_error;
551       fnd_msg_pub.count_and_get( p_count => x_msg_count
552                                , p_data  => x_msg_data );
553    WHEN OTHERS THEN
554       ROLLBACK TO stop_schedule_pub;
555       x_return_status := fnd_api.g_ret_sts_unexp_error;
556       IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
557          fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
558       END IF;
559       fnd_msg_pub.count_and_get( p_count => x_msg_count
560                                , p_data  => x_msg_data );
561 
562 END StopScheduleExecution;
563 
564 END IEC_SCHEDULE_MGMT_PUB;