84: l_return_status,
85: l_msg_Count,
86: l_msg_data);
87:
88: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
89: RAISE FND_API.G_EXC_ERROR ;
90: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
91: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
92: END IF ;
85: l_msg_Count,
86: l_msg_data);
87:
88: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
89: RAISE FND_API.G_EXC_ERROR ;
90: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
91: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
92: END IF ;
93:
86: l_msg_data);
87:
88: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
89: RAISE FND_API.G_EXC_ERROR ;
90: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
91: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
92: END IF ;
93:
94: X_GMT_DEV := l_e_GMT_dev;
87:
88: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
89: RAISE FND_API.G_EXC_ERROR ;
90: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
91: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
92: END IF ;
93:
94: X_GMT_DEV := l_e_GMT_dev;
95:
105: l_return_status,
106: l_msg_count,
107: l_msg_data);
108:
109: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
110: RAISE FND_API.G_EXC_ERROR ;
111: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
112: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
113: END IF ;
106: l_msg_count,
107: l_msg_data);
108:
109: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
110: RAISE FND_API.G_EXC_ERROR ;
111: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
112: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
113: END IF ;
114:
107: l_msg_data);
108:
109: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
110: RAISE FND_API.G_EXC_ERROR ;
111: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
112: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
113: END IF ;
114:
115: -- If time lag is null, then return the GMT offset of the Server time.
108:
109: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
110: RAISE FND_API.G_EXC_ERROR ;
111: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
112: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
113: END IF ;
114:
115: -- If time lag is null, then return the GMT offset of the Server time.
116:
124: x_return_status := l_return_status;
125:
126: EXCEPTION
127:
128: WHEN FND_API.G_EXC_ERROR THEN
129: ROLLBACK TO get_gmt_deviation;
130: x_return_status := FND_API.G_RET_STS_ERROR ;
131: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
132: p_data => x_msg_data ,
126: EXCEPTION
127:
128: WHEN FND_API.G_EXC_ERROR THEN
129: ROLLBACK TO get_gmt_deviation;
130: x_return_status := FND_API.G_RET_STS_ERROR ;
131: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
132: p_data => x_msg_data ,
133: p_encoded => fnd_api.g_false );
134:
129: ROLLBACK TO get_gmt_deviation;
130: x_return_status := FND_API.G_RET_STS_ERROR ;
131: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
132: p_data => x_msg_data ,
133: p_encoded => fnd_api.g_false );
134:
135: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
136: ROLLBACK TO get_gmt_deviation;
137: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
131: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
132: p_data => x_msg_data ,
133: p_encoded => fnd_api.g_false );
134:
135: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
136: ROLLBACK TO get_gmt_deviation;
137: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
138: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
139: p_data => x_msg_data ,
133: p_encoded => fnd_api.g_false );
134:
135: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
136: ROLLBACK TO get_gmt_deviation;
137: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
138: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
139: p_data => x_msg_data ,
140: p_encoded => fnd_api.g_false );
141:
136: ROLLBACK TO get_gmt_deviation;
137: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
138: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
139: p_data => x_msg_data ,
140: p_encoded => fnd_api.g_false );
141:
142: WHEN OTHERS THEN
143: ROLLBACK TO get_gmt_deviation;
144: x_return_status := FND_API.G_RET_STS_unexp_error ;
140: p_encoded => fnd_api.g_false );
141:
142: WHEN OTHERS THEN
143: ROLLBACK TO get_gmt_deviation;
144: x_return_status := FND_API.G_RET_STS_unexp_error ;
145:
146: IF fnd_msg_pub.check_msg_level( fnd_msg_pub.g_msg_lvl_unexp_error ) THEN
147: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name ) ;
148: END IF;
148: END IF;
149:
150: fnd_msg_pub.count_and_get (p_count =>x_msg_count ,
151: p_data => x_msg_data ,
152: p_encoded => fnd_api.g_false );
153:
154: END;
155:
156:
240: l_return_status,
241: l_msg_count,
242: l_msg_data);
243:
244: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
245: RAISE FND_API.G_EXC_ERROR ;
246: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
247: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
248: END IF ;
241: l_msg_count,
242: l_msg_data);
243:
244: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
245: RAISE FND_API.G_EXC_ERROR ;
246: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
247: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
248: END IF ;
249:
242: l_msg_data);
243:
244: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
245: RAISE FND_API.G_EXC_ERROR ;
246: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
247: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
248: END IF ;
249:
250: HZ_TIMEZONE_PUB.Get_Timezone_GMT_Deviation(p_api_version,
243:
244: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
245: RAISE FND_API.G_EXC_ERROR ;
246: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
247: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
248: END IF ;
249:
250: HZ_TIMEZONE_PUB.Get_Timezone_GMT_Deviation(p_api_version,
251: p_init_msg_list,
257: l_return_status,
258: l_msg_count,
259: l_msg_data);
260:
261: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
262: RAISE FND_API.G_EXC_ERROR ;
263: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
264: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
265: END IF ;
258: l_msg_count,
259: l_msg_data);
260:
261: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
262: RAISE FND_API.G_EXC_ERROR ;
263: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
264: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
265: END IF ;
266:
259: l_msg_data);
260:
261: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
262: RAISE FND_API.G_EXC_ERROR ;
263: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
264: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
265: END IF ;
266:
267: -- Calculate the timelag between two timezones.
260:
261: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
262: RAISE FND_API.G_EXC_ERROR ;
263: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
264: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
265: END IF ;
266:
267: -- Calculate the timelag between two timezones.
268:
269: x_leadtime := l_s_GMT_dev - l_e_GMT_dev;
270:
271: ELSE
272:
273: l_return_status := FND_API.G_RET_STS_SUCCESS;
274: x_leadtime := 0;
275:
276: END IF;
277:
278: x_return_status := l_return_status;
279:
280: EXCEPTION
281:
282: WHEN FND_API.G_EXC_ERROR THEN
283: ROLLBACK TO get_leadtime;
284: x_return_status := FND_API.G_RET_STS_ERROR ;
285: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
286: p_data => x_msg_data ,
280: EXCEPTION
281:
282: WHEN FND_API.G_EXC_ERROR THEN
283: ROLLBACK TO get_leadtime;
284: x_return_status := FND_API.G_RET_STS_ERROR ;
285: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
286: p_data => x_msg_data ,
287: p_encoded => fnd_api.g_false );
288:
283: ROLLBACK TO get_leadtime;
284: x_return_status := FND_API.G_RET_STS_ERROR ;
285: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
286: p_data => x_msg_data ,
287: p_encoded => fnd_api.g_false );
288:
289: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
290: ROLLBACK TO get_leadtime;
291: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
285: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
286: p_data => x_msg_data ,
287: p_encoded => fnd_api.g_false );
288:
289: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
290: ROLLBACK TO get_leadtime;
291: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
292: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
293: p_data => x_msg_data ,
287: p_encoded => fnd_api.g_false );
288:
289: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
290: ROLLBACK TO get_leadtime;
291: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
292: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
293: p_data => x_msg_data ,
294: p_encoded => fnd_api.g_false );
295:
290: ROLLBACK TO get_leadtime;
291: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
292: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
293: p_data => x_msg_data ,
294: p_encoded => fnd_api.g_false );
295:
296: WHEN OTHERS THEN
297: ROLLBACK TO get_leadtime;
298: x_return_status := FND_API.G_RET_STS_unexp_error ;
294: p_encoded => fnd_api.g_false );
295:
296: WHEN OTHERS THEN
297: ROLLBACK TO get_leadtime;
298: x_return_status := FND_API.G_RET_STS_unexp_error ;
299:
300: IF fnd_msg_pub.check_msg_level ( fnd_msg_pub.g_msg_lvl_unexp_error ) THEN
301: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name ) ;
302: END IF;
302: END IF;
303:
304: fnd_msg_pub.count_and_get ( p_count =>x_msg_count ,
305: p_data => x_msg_data ,
306: p_encoded => fnd_api.g_false );
307:
308: END;
309:
310:
390: l_return_status,
391: l_msg_count,
392: l_msg_data);
393:
394: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
395: RAISE FND_API.G_EXC_ERROR ;
396: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
397: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
398: END IF ;
391: l_msg_count,
392: l_msg_data);
393:
394: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
395: RAISE FND_API.G_EXC_ERROR ;
396: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
397: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
398: END IF ;
399:
392: l_msg_data);
393:
394: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
395: RAISE FND_API.G_EXC_ERROR ;
396: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
397: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
398: END IF ;
399:
400: -- Current System date is used in the Get_Timezone procedure to
393:
394: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
395: RAISE FND_API.G_EXC_ERROR ;
396: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
397: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
398: END IF ;
399:
400: -- Current System date is used in the Get_Timezone procedure to
401: -- find out the Daylight Savings time for the current year, if applicable.
425: l_msg_count,
426: l_msg_data);
427:
428:
429: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
430: RAISE FND_API.G_EXC_ERROR ;
431: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
432: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
433: END IF ;
426: l_msg_data);
427:
428:
429: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
430: RAISE FND_API.G_EXC_ERROR ;
431: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
432: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
433: END IF ;
434:
427:
428:
429: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
430: RAISE FND_API.G_EXC_ERROR ;
431: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
432: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
433: END IF ;
434:
435:
428:
429: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
430: RAISE FND_API.G_EXC_ERROR ;
431: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
432: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
433: END IF ;
434:
435:
436: HZ_TIMEZONE_PUB.Get_Timezone_GMT_Deviation(p_api_version,
443: l_return_status,
444: l_msg_count,
445: l_msg_data);
446:
447: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
448: RAISE FND_API.G_EXC_ERROR ;
449: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
450: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
451: END IF ;
444: l_msg_count,
445: l_msg_data);
446:
447: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
448: RAISE FND_API.G_EXC_ERROR ;
449: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
450: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
451: END IF ;
452:
445: l_msg_data);
446:
447: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
448: RAISE FND_API.G_EXC_ERROR ;
449: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
450: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
451: END IF ;
452:
453:
446:
447: IF (l_return_status = FND_API.G_RET_STS_ERROR ) THEN
448: RAISE FND_API.G_EXC_ERROR ;
449: ELSIF ( l_return_status = FND_API.G_RET_STS_UNEXP_ERROR ) THEN
450: RAISE FND_API.G_EXC_UNEXPECTED_ERROR ;
451: END IF ;
452:
453:
454: -- Calculate the timelag between two timezones.
456: x_leadtime := l_s_GMT_dev - l_e_GMT_dev;
457:
458: ELSE
459:
460: l_return_status := FND_API.G_RET_STS_SUCCESS;
461: x_leadtime := 0;
462:
463:
464: END IF;
466: x_return_status := l_return_status;
467:
468: EXCEPTION
469:
470: WHEN FND_API.G_EXC_ERROR THEN
471: ROLLBACK TO get_leadtime;
472: x_return_status := FND_API.G_RET_STS_ERROR ;
473: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
474: p_data => x_msg_data ,
468: EXCEPTION
469:
470: WHEN FND_API.G_EXC_ERROR THEN
471: ROLLBACK TO get_leadtime;
472: x_return_status := FND_API.G_RET_STS_ERROR ;
473: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
474: p_data => x_msg_data ,
475: p_encoded => fnd_api.g_false );
476:
471: ROLLBACK TO get_leadtime;
472: x_return_status := FND_API.G_RET_STS_ERROR ;
473: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
474: p_data => x_msg_data ,
475: p_encoded => fnd_api.g_false );
476:
477: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
478: ROLLBACK TO get_leadtime;
479: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
473: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
474: p_data => x_msg_data ,
475: p_encoded => fnd_api.g_false );
476:
477: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
478: ROLLBACK TO get_leadtime;
479: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
480: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
481: p_data => x_msg_data ,
475: p_encoded => fnd_api.g_false );
476:
477: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
478: ROLLBACK TO get_leadtime;
479: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
480: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
481: p_data => x_msg_data ,
482: p_encoded => fnd_api.g_false );
483:
478: ROLLBACK TO get_leadtime;
479: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
480: FND_MSG_PUB.COUNT_AND_GET (p_count =>x_msg_count ,
481: p_data => x_msg_data ,
482: p_encoded => fnd_api.g_false );
483:
484: WHEN OTHERS THEN
485: ROLLBACK TO get_leadtime;
486: x_return_status := FND_API.G_RET_STS_unexp_error ;
482: p_encoded => fnd_api.g_false );
483:
484: WHEN OTHERS THEN
485: ROLLBACK TO get_leadtime;
486: x_return_status := FND_API.G_RET_STS_unexp_error ;
487:
488: IF fnd_msg_pub.check_msg_level ( fnd_msg_pub.g_msg_lvl_unexp_error ) THEN
489: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name ) ;
490: END IF;
490: END IF;
491:
492: fnd_msg_pub.count_and_get (p_count =>x_msg_count ,
493: p_data => x_msg_data ,
494: p_encoded => fnd_api.g_false );
495:
496: END;
497: /*====================================================================================================+
498: ==