DBA Data[Home] [Help]

APPS.CST_REVENUECOGSMATCH_PVT dependencies on CST_REVENUE_COGS_MATCH_LINES

Line 788: cst_revenue_cogs_match_lines crcml,

784: cce.cogs_percentage cogs_percentage,
785: sum(cce.event_quantity) prior_event_quantity
786: FROM mtl_material_transactions mmt,
787: oe_order_lines_all ool,
788: cst_revenue_cogs_match_lines crcml,
789: cst_cogs_events cce,
790: mtl_secondary_inventories msi,
791: mtl_system_items_b item
792: ,cst_acct_info_v caiv --BUG#7463298

Line 1101: cst_revenue_cogs_match_lines crcml,

1097: crcml.cogs_acct_id,
1098: nvl(mp.process_enabled_flag,'N'),
1099: oap.acct_period_id -- acct period ID, I should store this in CCE so I don't keep having to go back to OAP
1100: FROM cst_cogs_events cce,
1101: cst_revenue_cogs_match_lines crcml,
1102: mtl_parameters mp,
1103: org_acct_periods oap,
1104: cst_acct_info_v caiv,
1105: mtl_system_items msi

Line 1407: FROM cst_revenue_cogs_match_lines crcml,

1403: ,MAX(mmt.transaction_id) mmt_transaction_id
1404: ,MAX(mmt.transaction_date) + clt.number_1 mmt_transaction_date
1405: ,MAX(mmt.acct_period_id) mmt_period_id
1406: --}
1407: FROM cst_revenue_cogs_match_lines crcml,
1408: cst_revenue_recognition_lines crrl,
1409: cst_cogs_events cce,
1410: mtl_parameters mp,
1411: gl_period_statuses gps,

Line 1567: cst_revenue_cogs_match_lines crcml,

1563: FROM ( SELECT
1564: DISTINCT caiv.organization_id,
1565: caiv.legal_entity
1566: FROM cst_revenue_recognition_lines crrl,
1567: cst_revenue_cogs_match_lines crcml,
1568: cst_acct_info_v caiv
1569: WHERE crrl.potentially_unmatched_flag='Y'
1570: AND DECODE(p_neg_req_id,NULL,NVL(crrl.request_id,-99),p_neg_req_id) = NVL(crrl.request_id,-99)
1571: -- BUG#7387575

Line 1594: cst_revenue_cogs_match_lines crcml,

1590: FROM ( SELECT
1591: DISTINCT caiv.organization_id,
1592: caiv.legal_entity
1593: FROM cst_revenue_recognition_lines crrl,
1594: cst_revenue_cogs_match_lines crcml,
1595: cst_acct_info_v caiv
1596: WHERE crrl.potentially_unmatched_flag='Y'
1597: AND crcml.revenue_om_line_id =crrl.revenue_om_line_id
1598: AND DECODE(p_neg_req_id,NULL,NVL(crrl.request_id,-99),p_neg_req_id) = NVL(crrl.request_id,-99)

Line 1637: -- FROM cst_revenue_cogs_match_lines crcml,

1633: -- TRUNC(MAX(cce.event_date-clt.number_1)) last_event_date,
1634: -- crrl.operating_unit_id,
1635: -- crrl.ledger_id,
1636: -- crrl.inventory_item_id
1637: -- FROM cst_revenue_cogs_match_lines crcml,
1638: -- cst_lists_temp clt,
1639: -- gl_period_statuses gps,
1640: -- cst_cogs_events cce,
1641: -- cst_revenue_recognition_lines crrl

Line 1755: cst_revenue_cogs_match_lines crcml,

1751:
1752: SELECT min(crrl.acct_period_num)
1753: INTO l_revenue_acct_period_num
1754: FROM cst_revenue_recognition_lines crrl,
1755: cst_revenue_cogs_match_lines crcml,
1756: cst_cogs_events cce,
1757: cst_lists_temp clt,
1758: gl_period_statuses gps
1759: --{

Line 1797: cst_revenue_cogs_match_lines crcml,

1793:
1794: SELECT min(crrl.acct_period_num)
1795: INTO l_revenue_acct_period_num
1796: FROM cst_revenue_recognition_lines crrl,
1797: cst_revenue_cogs_match_lines crcml,
1798: cst_cogs_events cce,
1799: cst_lists_temp clt,
1800: gl_period_statuses gps
1801: WHERE crrl.ledger_id = l_sob --l_sob.set_of_books_id

Line 2661: INSERT INTO cst_revenue_cogs_match_lines (

2657: -- Insert a new row into CRCML - if it already has this row, the unique index will be violated (DUP_VAL_ON_INDEX)
2658: BEGIN
2659: l_stmt_num := 30;
2660: debug(l_stmt_num);
2661: INSERT INTO cst_revenue_cogs_match_lines (
2662: cogs_om_line_id,
2663: revenue_om_line_id,
2664: cogs_acct_id,
2665: deferred_cogs_acct_id,

Line 3158: cst_revenue_cogs_match_lines crcml,

3154: crcml.cogs_acct_id,
3155: nvl(mp.process_enabled_flag,'N'),
3156: oap.acct_period_id
3157: FROM cst_cogs_events cce,
3158: cst_revenue_cogs_match_lines crcml,
3159: mtl_parameters mp,
3160: org_acct_periods oap,
3161: cst_acct_info_v caiv,
3162: mtl_system_items msi

Line 3499: UPDATE cst_revenue_cogs_match_lines crcml

3495: -- It's possible that two or more MMT transactions get created for the same sales
3496: -- order line, that's why it is necessary to first check whether the quantity
3497: -- already has a value and, if so, perform an average of the new parameters
3498: -- and whatever is already in the table already for these columns.
3499: UPDATE cst_revenue_cogs_match_lines crcml
3500: SET unit_material_cost = decode(original_shipped_qty, NULL, p_unit_material_cost,
3501: ((unit_material_cost*original_shipped_qty) +
3502: (p_unit_material_cost*p_txn_quantity)) /
3503: (original_shipped_qty + p_txn_quantity)),

Line 3760: FROM cst_revenue_cogs_match_lines crcml

3756: l_elemental_cost(5),
3757: l_unit_cost,
3758: l_def_cogs_acct_id,
3759: l_cogs_acct_id
3760: FROM cst_revenue_cogs_match_lines crcml
3761: WHERE cogs_om_line_id = p_cogs_om_line_id
3762: AND pac_cost_type_id IS NULL;
3763:
3764: IF l_stmtLog THEN

Line 4012: FROM cst_revenue_cogs_match_lines crcml

4008: l_elemental_cost(4),
4009: l_elemental_cost(5),
4010: l_cogs_acct_id,
4011: l_def_cogs_acct_id
4012: FROM cst_revenue_cogs_match_lines crcml
4013: WHERE cogs_om_line_id = p_cogs_om_line_id
4014: AND pac_cost_type_id IS NULL;
4015:
4016: FOR i IN 1..5 LOOP

Line 4156: cst_revenue_cogs_match_lines crcml,

4152: crcml.unit_cost,
4153: sob.currency_code,
4154: NVL(mmt.transaction_source_id, -1)
4155: FROM cst_cogs_events cce,
4156: cst_revenue_cogs_match_lines crcml,
4157: mtl_parameters mp,
4158: gl_sets_of_books sob,
4159: mtl_material_transactions mmt -- joining here to use the index on costed_flag
4160: WHERE

Line 4702: INTO cst_revenue_cogs_match_lines crcml

4698: );
4699: END IF;
4700:
4701: MERGE
4702: INTO cst_revenue_cogs_match_lines crcml
4703: USING (
4704: SELECT cogs_om_line_id,
4705: p_cost_type_id pac_cost_type_id,
4706: revenue_om_line_id,

Line 4715: FROM cst_revenue_cogs_match_lines

4711: operating_unit_id,
4712: ledger_id,
4713: sales_order_issue_date,
4714: original_shipped_qty
4715: FROM cst_revenue_cogs_match_lines
4716: WHERE cogs_om_line_id = l_cogs_om_line_id
4717: AND pac_cost_type_id IS NULL
4718: ) X
4719: ON (

Line 4883: FROM cst_revenue_cogs_match_lines crcml

4879: l_elemental_cost(4),
4880: l_elemental_cost(5),
4881: l_def_cogs_acct_id,
4882: l_cogs_acct_id
4883: FROM cst_revenue_cogs_match_lines crcml
4884: WHERE cogs_om_line_id = p_cogs_om_line_id
4885: AND pac_cost_type_id = p_ae_txn_rec.cost_type_id;
4886:
4887:

Line 5064: FROM cst_revenue_cogs_match_lines crcml

5060: l_elemental_cost(4),
5061: l_elemental_cost(5),
5062: l_def_cogs_acct_id,
5063: l_cogs_acct_id
5064: FROM cst_revenue_cogs_match_lines crcml
5065: WHERE cogs_om_line_id = p_ae_txn_rec.om_line_id
5066: AND pac_cost_type_id = p_ae_txn_rec.cost_type_id;
5067:
5068: l_stmt_num := 20;

Line 5968: CST_REVENUE_COGS_MATCH_LINES CRCML,

5964: CRCML.DEFERRED_COGS_ACCT_ID,
5965: sum(decode(mta.accounting_line_type, 35, MTA.BASE_TRANSACTION_VALUE,0)) COGS_BALANCE,
5966: sum(decode(mta.accounting_line_type, 36, MTA.BASE_TRANSACTION_VALUE,0)) DEF_COGS_BALANCE
5967: FROM
5968: CST_REVENUE_COGS_MATCH_LINES CRCML,
5969: CST_COGS_EVENTS CCE,
5970: GL_PERIOD_STATUSES GPS,
5971: OE_ORDER_LINES_ALL OOL,
5972: OE_ORDER_HEADERS_ALL OOH,

Line 6179: CST_REVENUE_COGS_MATCH_LINES CRCML,

6175: CRCML.DEFERRED_COGS_ACCT_ID,
6176: sum(decode(CAL.ae_line_type_code, 35, nvl(CAL.accounted_dr,0) - nvl(CAL.accounted_cr,0),0)) COGS_BALANCE,
6177: sum(decode(CAL.ae_line_type_code, 36, nvl(CAL.accounted_dr,0) - nvl(CAL.accounted_cr,0),0)) DEF_COGS_BALANCE
6178: FROM
6179: CST_REVENUE_COGS_MATCH_LINES CRCML,
6180: CST_COGS_EVENTS CCE,
6181: OE_ORDER_LINES_ALL OOL,
6182: OE_ORDER_HEADERS_ALL OOH,
6183: CST_COST_GROUP_ASSIGNMENTS CCGA,