1591: l_batch_id IN gme_batch_header.batch_id%TYPE
1592: )
1593: IS
1594: SELECT count(1)
1595: FROM cm_cmpt_dtl cst,
1596: cm_acst_led aled,
1597: gme_material_details md,
1598: gme_batch_header bh
1599: WHERE bh.batch_id = l_batch_id
2033: l_msg_data VARCHAR2(2000);
2034: l_total_cost NUMBER;
2035: l_no_of_rows NUMBER(10);
2036: l_cost_method CM_MTHD_MST.COST_MTHD_CODE%TYPE;
2037: l_cost_component_class_id CM_CMPT_DTL.COST_CMPNTCLS_ID%TYPE;
2038: l_cost_analysis_code CM_CMPT_DTL.COST_ANALYSIS_CODE%TYPE;
2039: l_api_name CONSTANT VARCHAR2(30) := 'Process_Item_Unit_Cost' ;
2040: l_api_version CONSTANT NUMBER := 1.0 ;
2041:
2034: l_total_cost NUMBER;
2035: l_no_of_rows NUMBER(10);
2036: l_cost_method CM_MTHD_MST.COST_MTHD_CODE%TYPE;
2037: l_cost_component_class_id CM_CMPT_DTL.COST_CMPNTCLS_ID%TYPE;
2038: l_cost_analysis_code CM_CMPT_DTL.COST_ANALYSIS_CODE%TYPE;
2039: l_api_name CONSTANT VARCHAR2(30) := 'Process_Item_Unit_Cost' ;
2040: l_api_version CONSTANT NUMBER := 1.0 ;
2041:
2042: /********************************************
2162: l_msg_data VARCHAR2(2000);
2163: l_total_cost NUMBER;
2164: l_no_of_rows NUMBER(10);
2165: l_cost_method CM_MTHD_MST.COST_MTHD_CODE%TYPE;
2166: l_cost_component_class_id CM_CMPT_DTL.COST_CMPNTCLS_ID%TYPE;
2167: l_cost_analysis_code CM_CMPT_DTL.COST_ANALYSIS_CODE%TYPE;
2168: l_api_name CONSTANT VARCHAR2(30) := 'Process_Item_Unit_Cost' ;
2169: l_api_version CONSTANT NUMBER := 1.0 ;
2170:
2163: l_total_cost NUMBER;
2164: l_no_of_rows NUMBER(10);
2165: l_cost_method CM_MTHD_MST.COST_MTHD_CODE%TYPE;
2166: l_cost_component_class_id CM_CMPT_DTL.COST_CMPNTCLS_ID%TYPE;
2167: l_cost_analysis_code CM_CMPT_DTL.COST_ANALYSIS_CODE%TYPE;
2168: l_api_name CONSTANT VARCHAR2(30) := 'Process_Item_Unit_Cost' ;
2169: l_api_version CONSTANT NUMBER := 1.0 ;
2170:
2171: /********************************************
2268: * FUNCTION
2269: * get_cmpt_cost
2270: * DESCRIPTION
2271: *
2272: * This function gets item unit cost from cm_cmpt_dtl, NOT from gl_item_cst/dtl.
2273: * This is being use in OPM Batch Cost Detail Report.
2274: *
2275: * AUTHOR
2276: * Anand Thiyagarajan 20-Feb-2007 Bug#5436964 Batches Across Periods FP
2309: v_cost_type_id NUMBER
2310: )
2311: IS
2312: SELECT nvl(sum(cst.cmpnt_cost), 0)
2313: FROM cm_cmpt_dtl cst,
2314: gmf_organization_definitions god,
2315: gmf_fiscal_policies f,
2316: gmf_period_statuses gps,
2317: (