DBA Data[Home] [Help]

APPS.PN_DISTRIBUTIONS_PKG dependencies on PN_DISTRIBUTIONS_ALL

Line 52: l_org_id pn_distributions_all.org_id%TYPE ;

48: )
49: IS
50: l_return_status VARCHAR2 (30) := NULL;
51: l_rowid VARCHAR2 (18) := NULL;
52: l_org_id pn_distributions_all.org_id%TYPE ;
53: l_vendor_site_id NUMBER;
54: l_term_le_ID NUMBER;
55:
56: l_count NUMBER;

Line 89: FROM pn_distributions_all pd

85: l_term_le_ID := rec.legal_entity_id;
86: END LOOP;
87:
88: SELECT count(*) INTO l_count
89: FROM pn_distributions_all pd
90: WHERE pd.payment_term_id = x_payment_term_id;
91:
92: IF pn_r12_util_pkg.is_r12 AND (l_count < 1)THEN
93: l_legal_entity_id :=

Line 141: FROM pn_distributions_all

137: IF x_payment_term_id IS NOT NULL THEN
138:
139: SELECT NVL(MAX(line_number),0) + 1
140: INTO x_line_number
141: FROM pn_distributions_all
142: WHERE payment_term_id = x_payment_term_id;
143:
144: ELSIF x_term_template_id IS NOT NULL THEN
145:

Line 148: FROM pn_distributions_all

144: ELSIF x_term_template_id IS NOT NULL THEN
145:
146: SELECT NVL(MAX(line_number),0) + 1
147: INTO x_line_number
148: FROM pn_distributions_all
149: WHERE term_template_id = x_term_template_id;
150:
151: END IF;
152:

Line 155: INSERT INTO pn_distributions_all

151: END IF;
152:
153: END IF;
154:
155: INSERT INTO pn_distributions_all
156: (distribution_id
157: ,account_id
158: ,payment_term_id
159: ,term_template_id

Line 284: FROM pn_distributions_all dist,

280:
281: --PNP_DEBUG_PKG.debug (' PN_DISTRIBUTIONS_PKG.update_row (+)');
282:
283: SELECT count(*) INTO l_count
284: FROM pn_distributions_all dist,
285: pn_payment_terms_all term
286: WHERE dist.payment_term_id = term.payment_term_id
287: AND term.payment_term_id = x_payment_term_id
288: AND dist.distribution_id <> x_distribution_id;

Line 309: UPDATE pn_distributions_all

305: END IF;
306: END LOOP;
307: END IF;
308:
309: UPDATE pn_distributions_all
310: SET account_id = x_account_id
311: ,payment_term_id = x_payment_term_id
312: ,term_template_id = x_term_template_id
313: ,account_class = x_account_class

Line 389: FROM pn_distributions_all

385: IS
386: CURSOR c1
387: IS
388: SELECT *
389: FROM pn_distributions_all
390: WHERE distribution_id = x_distribution_id
391: FOR UPDATE OF distribution_id NOWAIT;
392:
393: tlinfo c1%ROWTYPE;

Line 458: pn_distributions_all dist

454: term.legal_entity_id,
455: term.org_id,
456: dist.account_id
457: FROM pn_payment_terms_all term,
458: pn_distributions_all dist
459: WHERE term.payment_term_id = dist.payment_term_id (+)
460: AND term.payment_term_id = p_term_id
461: AND rownum < 2;
462:

Line 466: DELETE FROM pn_distributions_all

462:
463: BEGIN
464:
465: --PNP_DEBUG_PKG.debug (' PN_DISTRIBUTIONS_PKG.delete_row (+)');
466: DELETE FROM pn_distributions_all
467: WHERE ROWID = x_rowid
468: RETURNING payment_term_id INTO l_term_id;
469:
470: IF (SQL%NOTFOUND)

Line 523: pn_distributions_all dist

519: term.legal_entity_id,
520: term.org_id,
521: dist.account_id
522: FROM pn_payment_terms_all term,
523: pn_distributions_all dist
524: WHERE term.payment_term_id = dist.payment_term_id (+)
525: AND term.payment_term_id = p_term_id
526: AND rownum < 2;
527:

Line 531: DELETE FROM pn_distributions_all

527:
528: BEGIN
529:
530: --PNP_DEBUG_PKG.debug (' PN_DISTRIBUTIONS_PKG.delete_row (+)');
531: DELETE FROM pn_distributions_all
532: WHERE distribution_id = x_distribution_id
533: RETURNING payment_term_id INTO l_term_id;
534:
535: IF (SQL%NOTFOUND)