21: BEGIN
22: delete from ozf_offr_disc_struct_name_tl T
23: where not exists
24: (select NULL
25: from ozf_offr_disc_struct_name_b b
26: where b.offr_disc_struct_name_id = t.offr_disc_struct_name_id
27: );
28:
29: update ozf_offr_disc_struct_name_tl t set (
113: x_rowid VARCHAR2(30);
114: BEGIN
115: px_object_version_number := nvl(px_object_version_number, 1);
116:
117: INSERT INTO ozf_offr_disc_struct_name_b(
118: offr_disc_struct_name_id
119: , offer_discount_line_id
120: , object_version_number
121: , creation_date
190: , px_object_version_number IN OUT NOCOPY NUMBER
191: )
192: IS
193: BEGIN
194: Update ozf_offr_disc_struct_name_b
195: SET
196: offr_disc_struct_name_id = DECODE( p_offr_disc_struct_name_id, null, offr_disc_struct_name_id, FND_API.G_MISS_NUM, null, p_offr_disc_struct_name_id)
197: , offer_discount_line_id = DECODE( p_offer_discount_line_id, null, offer_discount_line_id, FND_API.G_MISS_NUM, null, p_offer_discount_line_id)
198: , last_update_date = DECODE( p_last_update_date, to_date(null), last_update_date, FND_API.G_MISS_DATE, to_date(NULL), p_last_update_date)
246: If (SQL%NOTFOUND) then
247: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
248: End If;
249:
250: DELETE FROM ozf_offr_disc_struct_name_b
251: WHERE offr_disc_struct_name_id = p_offr_disc_struct_name_id
252: AND object_version_number = p_object_version_number;
253:
254: If (SQL%NOTFOUND) then
275: p_object_version_number NUMBER)
276: IS
277: CURSOR C IS
278: SELECT *
279: FROM ozf_offr_disc_struct_name_b
280: WHERE offr_disc_struct_name_id = p_offr_disc_struct_name_id
281: AND object_version_number = p_object_version_number
282: FOR UPDATE OF offr_disc_struct_name_id NOWAIT;
283: Recinfo C%ROWTYPE;
314: BEGIN
315: delete from ozf_offr_disc_struct_name_tl T
316: where not exists
317: (select NULL
318: from ozf_offr_disc_struct_name_b b
319: where b.offr_disc_struct_name_id = t.offr_disc_struct_name_id
320: );
321:
322: update ozf_offr_disc_struct_name_tl t set (