DBA Data[Home] [Help]

APPS.PO_DOCUMENT_UPDATE_PVT dependencies on PO_LINES_ALL

Line 246: -- PO_LINES_ALL, etc.).

242: -- resp_appl_id => 201 );
243: --Modifies:
244: -- If all validations are successful, the requested and derived changes
245: -- will be applied to the database tables (ex. PO_HEADERS_ALL,
246: -- PO_LINES_ALL, etc.).
247: -- p_changes will be updated with all of the derived changes, including
248: -- the new LINE_LOCATION_ID and PO_DISTRIBUTION_ID for each split shipment
249: -- and split distribution.
250: --Locks:

Line 783: p_table_name => 'PO_LINES_ALL',

779: add_error (
780: p_api_errors => g_api_errors,
781: x_return_status => x_return_status,
782: p_message_name => 'PO_INVALID_DOC_IDS',
783: p_table_name => 'PO_LINES_ALL',
784: p_column_name => 'PO_LINE_ID',
785: p_entity_type => G_ENTITY_TYPE_LINES,
786: p_entity_id => i
787: );

Line 1545: p_table_name => 'PO_LINES_ALL',

1541: WHEN OTHERS THEN
1542: add_error ( p_api_errors => g_api_errors,
1543: x_return_status => x_return_status,
1544: p_message_name => 'PO_CHNG_INVALID_UOM_CONVERSION',
1545: p_table_name => 'PO_LINES_ALL',
1546: p_column_name => 'UNIT_MEAS_LOOKUP_CODE',
1547: p_entity_type => G_ENTITY_TYPE_LINES,
1548: p_entity_id => i );
1549: RETURN;

Line 1592: p_table_name => 'PO_LINES_ALL',

1588: WHEN OTHERS THEN
1589: add_error ( p_api_errors => g_api_errors,
1590: x_return_status => x_return_status,
1591: p_message_name => 'PO_CHNG_INVALID_UOM_CONVERSION',
1592: p_table_name => 'PO_LINES_ALL',
1593: p_column_name => 'UNIT_MEAS_LOOKUP_CODE',
1594: p_entity_type => G_ENTITY_TYPE_SHIPMENTS,
1595: p_entity_id => i );
1596: RETURN;

Line 1639: p_table_name => 'PO_LINES_ALL',

1635: WHEN OTHERS THEN
1636: add_error ( p_api_errors => g_api_errors,
1637: x_return_status => x_return_status,
1638: p_message_name => 'PO_CHNG_INVALID_UOM_CONVERSION',
1639: p_table_name => 'PO_LINES_ALL',
1640: p_column_name => 'UNIT_MEAS_LOOKUP_CODE',
1641: p_entity_type => G_ENTITY_TYPE_DISTRIBUTIONS,
1642: p_entity_id => i );
1643: RETURN;

Line 1764: p_table_name => 'PO_LINES_ALL',

1760: IF (l_shipment_count > 1) THEN -- The line has multiple shipments
1761: add_error ( p_api_errors => g_api_errors,
1762: x_return_status => x_return_status,
1763: p_message_name => 'PO_CHNG_QTY_AMT_MULTI_SHIP',
1764: p_table_name => 'PO_LINES_ALL',
1765: p_column_name => null,
1766: p_entity_type => G_ENTITY_TYPE_LINES,
1767: p_entity_id => i );
1768: END IF; -- l_num_shipments

Line 1784: p_table_name => 'PO_LINES_ALL',

1780:
1781: add_error ( p_api_errors => g_api_errors,
1782: x_return_status => x_return_status,
1783: p_message_name => 'PO_CHNG_QTY2_NO_UOM2',
1784: p_table_name => 'PO_LINES_ALL',
1785: p_column_name => 'SECONDARY_QUANTITY',
1786: p_entity_type => G_ENTITY_TYPE_LINES,
1787: p_entity_id => i );
1788: END IF;

Line 1803: p_table_name => 'PO_LINES_ALL',

1799:
1800: add_error ( p_api_errors => g_api_errors,
1801: x_return_status => x_return_status,
1802: p_message_name => 'PO_CHNG_QTY2_NO_QTY',
1803: p_table_name => 'PO_LINES_ALL',
1804: p_column_name => 'SECONDARY_QUANTITY',
1805: p_entity_type => G_ENTITY_TYPE_LINES,
1806: p_entity_id => i );
1807: END IF;

Line 1831: p_table_name => 'PO_LINES_ALL',

1827: IF l_grade_control_flag = 'N' THEN
1828: add_error ( p_api_errors => g_api_errors,
1829: x_return_status => x_return_status,
1830: p_message_name => 'INV_ITEM_NOT_GRADE_CTRL_EXP',
1831: p_table_name => 'PO_LINES_ALL',
1832: p_column_name => 'PREFERRED_GRADE',
1833: p_entity_type => G_ENTITY_TYPE_LINES,
1834: p_entity_id => i);
1835: END IF;

Line 1858: p_table_name => 'PO_LINES_ALL',

1854: IF (l_dual_uom_ind = 'P') THEN
1855: add_error ( p_api_errors => g_api_errors,
1856: x_return_status => x_return_status,
1857: p_message_name => 'PO_CHNG_NON_DUAL_ITEM',
1858: p_table_name => 'PO_LINES_ALL',
1859: p_column_name => 'SECONDARY_QUANTITY',
1860: p_entity_type => G_ENTITY_TYPE_LINES,
1861: p_entity_id => i );
1862:

Line 1898: p_table_name => 'PO_LINES_ALL',

1894: IF (l_dual_uom_ind = 'P') THEN
1895: add_error ( p_api_errors => g_api_errors,
1896: x_return_status => x_return_status,
1897: p_message_name => 'PO_CHNG_NON_DUAL_ITEM',
1898: p_table_name => 'PO_LINES_ALL',
1899: p_column_name => 'SECONDARY_QUANTITY',
1900: p_entity_type => G_ENTITY_TYPE_LINES,
1901: p_entity_id => i );
1902:

Line 2214: p_table_name => 'PO_LINES_ALL',

2210: OR (p_chg.line_changes.amount(i) IS NOT NULL) THEN
2211: add_error ( p_api_errors => g_api_errors,
2212: x_return_status => x_return_status,
2213: p_message_name => 'PO_CHNG_BLKT_LINE_BAD_FIELD',
2214: p_table_name => 'PO_LINES_ALL',
2215: p_column_name => 'QUANTITY',
2216: p_token_name1 => 'COLUMN_NAME',
2217: p_token_value1 => 'QUANTITY',
2218: p_entity_type => G_ENTITY_TYPE_LINES,

Line 2290: p_table_name => 'PO_LINES_ALL',

2286: IF (g_document_type = 'RELEASE') AND (p_chg.line_changes.get_count > 0) THEN
2287: add_error ( p_api_errors => g_api_errors,
2288: x_return_status => x_return_status,
2289: p_message_name => 'PO_CHNG_RELEASE_NO_LINES',
2290: p_table_name => 'PO_LINES_ALL',
2291: p_column_name => null,
2292: p_entity_type => G_ENTITY_TYPE_LINES );
2293: END IF;
2294:

Line 2333: p_table_name => 'PO_LINES_ALL',p_column_name => 'PRICE',

2329:
2330: IF (p_chg.line_changes.unit_price(i) IS NOT NULL ) THEN
2331: add_error( p_api_errors => g_api_errors,x_return_status => x_return_status,
2332: p_message_name => 'PO_NO_PRICE_CHNG_FP_LINES',
2333: p_table_name => 'PO_LINES_ALL',p_column_name => 'PRICE',
2334: p_entity_type => g_entity_type_lines,p_entity_id => i);
2335: END IF;
2336: ELSIF (p_chg.line_changes.c_value_basis(i) = 'AMOUNT') THEN
2337: ------------------------------------------------------------------------

Line 2344: p_table_name => 'PO_LINES_ALL',p_column_name => 'PRICE',

2340:
2341: IF (p_chg.line_changes.unit_price(i) IS NOT NULL ) THEN
2342: add_error( p_api_errors => g_api_errors,x_return_status => x_return_status,
2343: p_message_name => 'PO_NO_PRICE_CHNG_AMT_LINES',
2344: p_table_name => 'PO_LINES_ALL',p_column_name => 'PRICE',
2345: p_entity_type => g_entity_type_lines,p_entity_id => i);
2346: END IF;
2347: END IF;
2348: --< BUG 5406211 END >

Line 2362: p_table_name => 'PO_LINES_ALL',

2358: IF (p_chg.line_changes.quantity(i) IS NOT NULL) THEN
2359: add_error ( p_api_errors => g_api_errors,
2360: x_return_status => x_return_status,
2361: p_message_name => 'PO_SVC_NO_QTY',
2362: p_table_name => 'PO_LINES_ALL',
2363: p_column_name => 'QUANTITY',
2364: p_entity_type => G_ENTITY_TYPE_LINES,
2365: p_entity_id => i );
2366: END IF;

Line 2378: p_table_name => 'PO_LINES_ALL',

2374: IF (p_chg.line_changes.amount(i) IS NOT NULL) THEN
2375: add_error ( p_api_errors => g_api_errors,
2376: x_return_status => x_return_status,
2377: p_message_name => 'PO_SVC_NO_AMT',
2378: p_table_name => 'PO_LINES_ALL',
2379: p_column_name => 'AMOUNT',
2380: p_entity_type => G_ENTITY_TYPE_LINES,
2381: p_entity_id => i );
2382: END IF;

Line 2399: p_table_name => 'PO_LINES_ALL',

2395: IF (p_chg.line_changes.start_date(i) IS NOT NULL) THEN
2396: add_error ( p_api_errors => g_api_errors,
2397: x_return_status => x_return_status,
2398: p_message_name => 'PO_SVC_NO_START_END_DATE',
2399: p_table_name => 'PO_LINES_ALL',
2400: p_column_name => 'START_DATE',
2401: p_entity_type => G_ENTITY_TYPE_LINES,
2402: p_entity_id => i );
2403: END IF;

Line 2409: p_table_name => 'PO_LINES_ALL',

2405: IF (p_chg.line_changes.expiration_date(i) IS NOT NULL) THEN
2406: add_error ( p_api_errors => g_api_errors,
2407: x_return_status => x_return_status,
2408: p_message_name => 'PO_SVC_NO_START_END_DATE',
2409: p_table_name => 'PO_LINES_ALL',
2410: p_column_name => 'EXPIRATION_DATE',
2411: p_entity_type => G_ENTITY_TYPE_LINES,
2412: p_entity_id => i );
2413: END IF;

Line 2629: l_table_name := 'PO_LINES_ALL';

2625: l_new_quantity := p_chg.line_changes.quantity(i);
2626: l_new_price := p_chg.line_changes.unit_price(i);
2627: l_new_amount := p_chg.line_changes.amount(i);
2628:
2629: l_table_name := 'PO_LINES_ALL';
2630: l_qty_column_name := 'QUANTITY';
2631: l_price_column_name := 'UNIT_PRICE';
2632: l_amt_column_name := 'AMOUNT';
2633: ELSIF (p_entity_type = G_ENTITY_TYPE_SHIPMENTS) THEN

Line 5231: p_table_name => 'PO_LINES_ALL',

5227: add_error ( p_api_errors => g_api_errors,
5228: x_return_status => x_return_status,
5229: p_message_name => 'PO_CHNG_AMT_LESS_ADV',
5230: --Line amount must be greater than or equal to the Advance amount.
5231: p_table_name => 'PO_LINES_ALL',
5232: p_entity_type => G_ENTITY_TYPE_LINES,
5233: p_entity_id => i );
5234: end if;
5235: END IF;

Line 5248: p_table_name => 'PO_LINES_ALL',

5244: OR (p_chg.line_changes.c_closed_code(i) = 'FINALLY CLOSED') THEN
5245: add_error ( p_api_errors => g_api_errors,
5246: x_return_status => x_return_status,
5247: p_message_name => 'PO_CHNG_CANNOT_MODIFY_LINE',
5248: p_table_name => 'PO_LINES_ALL',
5249: p_entity_type => G_ENTITY_TYPE_LINES,
5250: p_entity_id => i );
5251: END IF;
5252:

Line 5277: p_table_name => 'PO_LINES_ALL',

5273: IF (l_new_qty < greatest(l_qty_received, l_qty_billed)) THEN
5274: add_error ( p_api_errors => g_api_errors,
5275: x_return_status => x_return_status,
5276: p_message_name => 'PO_CHNG_QTY_RESTRICTED',
5277: p_table_name => 'PO_LINES_ALL',
5278: p_column_name => 'QUANTITY',
5279: p_entity_type => G_ENTITY_TYPE_LINES,
5280: p_entity_id => i );
5281: END IF;

Line 5297: p_table_name => 'PO_LINES_ALL',

5293: IF (l_new_qty < greatest(l_qty_received, l_qty_billed)) THEN
5294: add_error ( p_api_errors => g_api_errors,
5295: x_return_status => x_return_status,
5296: p_message_name => 'PO_CHNG_QTY_RESTRICTED',
5297: p_table_name => 'PO_LINES_ALL',
5298: p_column_name => 'QUANTITY',
5299: p_entity_type => G_ENTITY_TYPE_LINES,
5300: p_entity_id => i );
5301: END IF;

Line 5366: p_table_name => 'PO_LINES_ALL',

5362:
5363: add_error ( p_api_errors => g_api_errors,
5364: x_return_status => x_return_status,
5365: p_message_name => 'PO_SVC_END_GE_START',
5366: p_table_name => 'PO_LINES_ALL',
5367: p_entity_type => G_ENTITY_TYPE_LINES,
5368: p_entity_id => i );
5369: END IF;
5370:

Line 5396: p_table_name => 'PO_LINES_ALL',

5392: IF (l_new_amount < greatest(l_amt_received, l_amt_billed)) THEN
5393: add_error ( p_api_errors => g_api_errors,
5394: x_return_status => x_return_status,
5395: p_message_name => 'PO_CHNG_AMT_RESTRICTED',
5396: p_table_name => 'PO_LINES_ALL',
5397: p_column_name => 'AMOUNT',
5398: p_entity_type => G_ENTITY_TYPE_LINES,
5399: p_entity_id => i );
5400: END IF;

Line 5419: p_table_name => 'PO_LINES_ALL',

5415: IF (l_new_amount < greatest(l_amt_received, l_amt_billed)) THEN
5416: add_error ( p_api_errors => g_api_errors,
5417: x_return_status => x_return_status,
5418: p_message_name => 'PO_CHNG_AMT_RESTRICTED',
5419: p_table_name => 'PO_LINES_ALL',
5420: p_column_name => 'AMOUNT',
5421: p_entity_type => G_ENTITY_TYPE_LINES,
5422: p_entity_id => i );
5423: END IF;

Line 5464: p_table_name => 'PO_LINES_ALL',

5460: IF (l_timecard_exists) THEN
5461: add_error ( p_api_errors => g_api_errors,
5462: x_return_status => x_return_status,
5463: p_message_name => 'PO_CHNG_OTL_NO_PRICE_CHANGE',
5464: p_table_name => 'PO_LINES_ALL',
5465: p_column_name => 'UNIT_PRICE',
5466: p_entity_type => G_ENTITY_TYPE_LINES,
5467: p_entity_id => i );
5468: END IF; -- l_timecard_exists

Line 5494: p_table_name => 'PO_LINES_ALL',

5490: IF (l_new_amount < l_timecard_amount_sum) THEN
5491: add_error ( p_api_errors => g_api_errors,
5492: x_return_status => x_return_status,
5493: p_message_name => 'PO_CHNG_OTL_INVALID_AMOUNT',
5494: p_table_name => 'PO_LINES_ALL',
5495: p_column_name => 'AMOUNT',
5496: -- PBWC Message Change Impact: Adding a token.
5497: p_token_name1 => 'TOTAL_AMT',
5498: p_token_value1 => to_char(l_timecard_amount_sum),

Line 5529: p_table_name => 'PO_LINES_ALL',

5525: IF (l_timecard_exists) THEN
5526: add_error ( p_api_errors => g_api_errors,
5527: x_return_status => x_return_status,
5528: p_message_name => 'PO_CHNG_OTL_INVALID_END_DATE',
5529: p_table_name => 'PO_LINES_ALL',
5530: p_column_name => 'EXPIRATION_DATE',
5531: p_entity_type => G_ENTITY_TYPE_LINES,
5532: p_entity_id => i );
5533: END IF; -- l_timecard_exists

Line 5563: p_table_name => 'PO_LINES_ALL',

5559:
5560: add_error ( p_api_errors => g_api_errors,
5561: x_return_status => x_return_status,
5562: p_message_name => 'PO_CHNG_OTL_INVALID_START_DATE',
5563: p_table_name => 'PO_LINES_ALL',
5564: p_column_name => 'START_DATE',
5565: p_entity_type => G_ENTITY_TYPE_LINES,
5566: p_entity_id => i );
5567:

Line 5590: p_table_name => 'PO_LINES_ALL',

5586: IF (g_approved_date IS NOT NULL) THEN
5587: add_error ( p_api_errors => g_api_errors,
5588: x_return_status => x_return_status,
5589: p_message_name => 'PO_PO_USE_CANCEL_ON_APRVD_PO2',
5590: p_table_name => 'PO_LINES_ALL',
5591: p_column_name => NULL,
5592: p_entity_type => G_ENTITY_TYPE_LINES,
5593: p_entity_id => i);
5594: END IF;

Line 5612: p_table_name => 'PO_LINES_ALL',

5608: IF (l_ship_count > 0) THEN
5609: add_error ( p_api_errors => g_api_errors,
5610: x_return_status => x_return_status,
5611: p_message_name => 'PO_PO_USE_CANCEL_ON_APRVD_PO2',
5612: p_table_name => 'PO_LINES_ALL',
5613: p_column_name => NULL,
5614: p_entity_type => G_ENTITY_TYPE_LINES,
5615: p_entity_id => i);
5616: END IF;

Line 5631: p_table_name => 'PO_LINES_ALL',

5627: IF (l_ship_count > 0) THEN
5628: add_error ( p_api_errors => g_api_errors,
5629: x_return_status => x_return_status,
5630: p_message_name => 'PO_PO_USE_CANCEL_ON_ENCUMB_PO',
5631: p_table_name => 'PO_LINES_ALL',
5632: p_column_name => NULL,
5633: p_entity_type => G_ENTITY_TYPE_LINES,
5634: p_entity_id => i);
5635: END IF;

Line 5724: l_allow_price_override PO_LINES.allow_price_override_flag%TYPE;

5720: l_approved_date PO_LINE_LOCATIONS.approved_date%TYPE;
5721: l_encumbered_flag PO_LINE_LOCATIONS.encumbered_flag%TYPE;
5722: l_shipment_type PO_LINE_LOCATIONS.shipment_type%TYPE;
5723: l_pending_rcv_transactions NUMBER;
5724: l_allow_price_override PO_LINES.allow_price_override_flag%TYPE;
5725: l_ship_to_loc_valid NUMBER;
5726: l_message_name VARCHAR2(30);
5727: l_new_sales_order_update_date PO_LINE_LOCATIONS.sales_order_update_date%TYPE;
5728:

Line 6669: -- Updates PO_HEADERS_ALL, PO_RELEASES_ALL, PO_LINES_ALL,

6665: -- Applies the requested and derived changes to the database tables.
6666: --Pre-reqs:
6667: -- None.
6668: --Modifies:
6669: -- Updates PO_HEADERS_ALL, PO_RELEASES_ALL, PO_LINES_ALL,
6670: -- PO_LINE_LOCATIONS_ALL, PO_DISTRIBUTIONS_ALL with the changes.
6671: --Locks:
6672: -- None.
6673: --End of Comments

Line 9186: FROM PO_LINES_ALL

9182:
9183: d_pos := 40;
9184: SELECT ROWID
9185: INTO l_entity_row_id
9186: FROM PO_LINES_ALL
9187: WHERE PO_LINE_ID = p_po_line_id;
9188:
9189: d_pos := 45;
9190: PO_LINES_SV.delete_line( X_type_lookup_code => p_doc_subtype