DBA Data[Home] [Help]

APPS.AP_INVOICE_LINES_UTILITY_PKG dependencies on AP_INVOICES_ALL

Line 58: FROM ap_invoices_all ai,

54: SELECT NVL(fsp.purch_encumbrance_flag,'N'),
55: ai.org_id
56: INTO l_purch_encumbrance_flag,
57: l_org_id
58: FROM ap_invoices_all ai,
59: financials_system_params_all fsp
60: WHERE ai.invoice_id = p_invoice_id
61: AND ai.org_id = fsp.org_id;
62:

Line 184: FROM ap_invoices_all ai,

180: SELECT nvl(sob.sla_ledger_cash_basis_flag, 'N'),
181: asp.org_id
182: INTO l_cash_basis_flag,
183: l_org_id
184: FROM ap_invoices_all ai,
185: ap_system_parameters_all asp,
186: gl_sets_of_books sob
187: WHERE ai.invoice_id = p_invoice_id
188: AND ai.org_id = asp.org_id

Line 277: -- MOAC. Included select from ap_invoices_all to get the org_id from

273: BEGIN
274:
275: ---------------------------------------------------------------------
276: -- Get the encumbrance flag
277: -- MOAC. Included select from ap_invoices_all to get the org_id from
278: -- the invoice_id since it is unique
279:
280: SELECT NVL(fsp.purch_encumbrance_flag,'N'), ai.org_id
281: INTO encumbrance_flag, l_org_id

Line 282: FROM ap_invoices_all ai,

278: -- the invoice_id since it is unique
279:
280: SELECT NVL(fsp.purch_encumbrance_flag,'N'), ai.org_id
281: INTO encumbrance_flag, l_org_id
282: FROM ap_invoices_all ai,
283: financials_system_params_all fsp
284: WHERE ai.invoice_id = p_invoice_id
285: AND ai.org_id = fsp.org_id;
286:

Line 492: l_org_id ap_invoices_all.org_id%type; -- for bug 5936290

488:
489: l_prepay_amount_applied NUMBER := 0;
490: l_enc_enabled VARCHAR2(1); --bug6009101
491: l_po_not_approved VARCHAR2(1); --bug6009101
492: l_org_id ap_invoices_all.org_id%type; -- for bug 5936290
493: CURSOR dist_gl_date_Cur IS
494: SELECT accounting_date
495: FROM ap_invoice_distributions AID
496: WHERE AID.invoice_id = p_line_rec.invoice_id

Line 553: FROM ap_invoices_all

549: -- So now we are passing the org_id also in these two calls.
550:
551: SELECT org_id
552: INTO l_org_id
553: FROM ap_invoices_all
554: WHERE invoice_id = p_line_rec.invoice_id;
555:
556: FOR i in NVL(l_gl_date_list.FIRST,0)..NVL(l_gl_date_list.LAST,-1)
557: LOOP

Line 720: ap_invoices_all AI

716:
717: SELECT NVL(purch_encumbrance_flag,'N')
718: INTO l_enc_enabled
719: FROM financials_system_params_all FSP,
720: ap_invoices_all AI
721: WHERE AI.invoice_id = p_line_rec.invoice_id
722: AND FSP.org_id = AI.org_id;
723:
724: if l_enc_enabled = 'Y' then

Line 957: FROM ap_invoices_all ai

953: | is applied. If so, return FALSE (Bug #5114854) |
954: +-----------------------------------------------------------------*/
955: SELECT count(*)
956: INTO l_count
957: FROM ap_invoices_all ai
958: WHERE invoice_id = p_line_rec.invoice_id
959: AND invoice_type_lookup_code = 'PREPAYMENT';
960:
961: IF ( l_count > 0 ) THEN

Line 1088: From ap_invoices_all AI

1084: --bug 5475668 Added the if condition
1085: if (p_invoice_id is not null) then
1086: Select 1
1087: Into dummy
1088: From ap_invoices_all AI
1089: Where AI.credited_invoice_id = p_Invoice_Id
1090: AND NVL(AI.quick_credit, 'N') = 'Y'
1091: AND AI.cancelled_date is null
1092: AND Rownum = 1;

Line 1721: l_invoice_id ap_invoices_all.invoice_id%TYPE;

1717: nvl( AID.quantity_invoiced,0 ) ) < 0
1718: OR
1719: NVL(POD.amount_billed, 0) - NVL(AID.amount, 0) < 0 );
1720:
1721: l_invoice_id ap_invoices_all.invoice_id%TYPE;
1722: current_calling_sequence VARCHAR2(4000);
1723: debug_info VARCHAR2(240);
1724: l_po_dist_count NUMBER := 0;
1725: l_return_var BOOLEAN := FALSE;

Line 2120: l_payment_cross_rate ap_invoices_all.payment_cross_rate%TYPE :=0;

2116: ) IS
2117:
2118: l_inv_amt_remaining ap_payment_schedules.amount_remaining%TYPE := 0;
2119: l_gross_amount ap_payment_schedules.gross_amount%TYPE := 0;
2120: l_payment_cross_rate ap_invoices_all.payment_cross_rate%TYPE :=0;
2121: l_payment_currency_code ap_invoices_all.payment_currency_code%TYPE;
2122:
2123: -- Debug variables
2124: l_debug_loc VARCHAR2(30) := 'Manual_Withhold_Tax';

Line 2121: l_payment_currency_code ap_invoices_all.payment_currency_code%TYPE;

2117:
2118: l_inv_amt_remaining ap_payment_schedules.amount_remaining%TYPE := 0;
2119: l_gross_amount ap_payment_schedules.gross_amount%TYPE := 0;
2120: l_payment_cross_rate ap_invoices_all.payment_cross_rate%TYPE :=0;
2121: l_payment_currency_code ap_invoices_all.payment_currency_code%TYPE;
2122:
2123: -- Debug variables
2124: l_debug_loc VARCHAR2(30) := 'Manual_Withhold_Tax';
2125: l_curr_calling_sequence VARCHAR2(2000);

Line 2135: FROM ap_invoices_all

2131: l_curr_calling_sequence := 'AP_INVOICE_LINES_UTILITY_PKG.'||l_debug_loc;
2132:
2133: SELECT nvl(payment_cross_rate,0), payment_currency_code
2134: INTO l_payment_cross_rate, l_payment_currency_code
2135: FROM ap_invoices_all
2136: WHERE invoice_id = p_invoice_id;
2137:
2138: SELECT sum(nvl(amount_remaining,0)), sum(nvl(gross_amount,0))
2139: INTO l_inv_amt_remaining, l_gross_amount