DBA Data[Home] [Help]

APPS.GMI_PRE_MIGRATION SQL Statements

The following lines contain the word 'select', 'insert', 'update' or 'delete':

Line: 57

SELECT col.descriptive_flex_context_code,
	col.application_column_name,
	col.end_user_column_name
FROM fnd_descr_flex_column_usages col,
	fnd_descr_flex_contexts cont
WHERE
	col.application_id = 551 and
	col.descriptive_flexfield_name = p_opm_desc_flex_name and
	col.enabled_flag = 'Y' and
	col.application_id = cont.application_id and
	col.descriptive_flexfield_name = cont.descriptive_flexfield_name and
	col.descriptive_flex_context_code = cont.descriptive_flex_context_code and
	cont.enabled_flag = 'Y' and
	col.application_column_name in (
		SELECT col2.application_column_name
		FROM fnd_descr_flex_column_usages col2,
			fnd_descr_flex_contexts cont2
		WHERE
			col2.application_id = 401 and
			col2.descriptive_flexfield_name = p_odm_desc_flex_name and
			col2.enabled_flag = 'Y' and
			col.application_id = cont2.application_id and
			col.descriptive_flexfield_name = cont2.descriptive_flexfield_name and
			col.descriptive_flex_context_code = cont2.descriptive_flex_context_code and
			cont2.enabled_flag = 'Y' );
Line: 85

SELECT col.descriptive_flex_context_code,
	col.application_column_name,
	col.end_user_column_name
FROM fnd_descr_flex_column_usages col,
	fnd_descr_flex_contexts cont
WHERE
	col.application_id = 551 and
	col.descriptive_flexfield_name = p_opm_desc_flex_name and
	col.enabled_flag = 'Y' and
	col.application_id = cont.application_id and
	col.descriptive_flexfield_name = cont.descriptive_flexfield_name and
	col.descriptive_flex_context_code = cont.descriptive_flex_context_code and
	cont.enabled_flag = 'Y';
Line: 112

		SELECT cont.descriptive_flex_context_code
		INTO l_opm_context
		FROM fnd_descr_flex_contexts cont
		WHERE cont.application_id = 551 and
			cont.descriptive_flexfield_name = p_opm_desc_flex_name and
			cont.enabled_flag = 'Y' and
			cont.global_flag = 'N' and
			rownum = 1;
Line: 125

		SELECT cont.descriptive_flex_context_code
		INTO l_odm_context
		FROM fnd_descr_flex_contexts cont
		WHERE cont.application_id = 401 and
			cont.descriptive_flexfield_name = p_odm_desc_flex_name and
			cont.enabled_flag = 'Y' and
			cont.global_flag = 'N' and
			rownum = 1;
Line: 200

SELECT count(*) item_count
FROM ic_item_mst_b
WHERE lot_ctl = 1 AND
    autolot_active_indicator <> 1;
Line: 206

SELECT i.item_no, l.lot_no, l.sublot_no, w.orgn_code, w.whse_code, inv.location, inv.lot_status
FROM ic_loct_inv inv, ic_item_mst_b i, ic_lots_mst l, ic_whse_mst w
WHERE
    inv.whse_code = w.whse_code AND
    inv.item_id = i.item_id AND
    i.lot_ctl = 1 AND
    inv.item_id = l.item_id AND
    inv.lot_id = l.lot_id AND
    inv.loct_onhand <> 0 AND
    EXISTS (
	SELECT 1
	FROM ic_loct_inv inv2, ic_whse_mst w2
	WHERE
	    inv.whse_code = w2.whse_code AND
	    inv.item_id = inv2.item_id AND
	    inv.lot_id = inv2.lot_id AND
			-- Compare the balances within the mapped org
		DECODE(w.subinventory_ind_flag, 'Y', w.orgn_code, w.whse_code) =
		DECODE(w2.subinventory_ind_flag, 'Y', w2.orgn_code, w2.whse_code) AND
			-- Same locations for whse mapped as subinventory will be created as diff locators.
		inv.whse_code||inv.location <> inv2.whse_code||inv2.location AND
	    inv.lot_status <> inv2.lot_status AND
	    inv2.loct_onhand <> 0)
ORDER by i.item_no, l.lot_no, l.sublot_no, w.orgn_code, w.whse_code, inv.location;
Line: 232

SELECT organization_code
FROM mtl_parameters
WHERE
    (organization_id IN (
        SELECT mtl_organization_id
        FROM ic_whse_mst) OR
    organization_id IN (
        SELECT organization_id
        FROM ic_whse_mst)) AND
    lot_number_uniqueness <> 2;
Line: 244

SELECT organization_code
FROM mtl_parameters
WHERE
    (organization_id IN (
        SELECT mtl_organization_id
        FROM ic_whse_mst
	WHERE loct_ctl = 1) OR
    organization_id IN (
        SELECT organization_id
        FROM ic_whse_mst
	WHERE loct_ctl = 1)) AND
    stock_locator_control_code <> 4;
Line: 258

SELECT distinct p.organization_code, s.secondary_inventory_name
FROM mtl_parameters p,
    mtl_secondary_inventories s,
    mtl_item_locations l,
    ic_loct_mst ol
WHERE
    p.organization_id = s.organization_id AND
    p.organization_id = l.organization_id AND
    s.secondary_inventory_name = l.subinventory_code AND
    l.inventory_location_id = ol.inventory_location_id AND
    s.locator_type <> 5 AND
    (p.organization_id IN (
        SELECT mtl_organization_id
        FROM ic_whse_mst
        WHERE loct_ctl = 1) OR
    p.organization_id IN (
        SELECT organization_id
        FROM ic_whse_mst
        WHERE loct_ctl = 1));
Line: 279

SELECT organization_code
FROM mtl_parameters
WHERE
    (organization_id IN (
        SELECT mtl_organization_id
        FROM ic_whse_mst
	WHERE loct_ctl = 0) OR
    organization_id IN (
        SELECT organization_id
        FROM ic_whse_mst
	WHERE loct_ctl = 0)) AND
    stock_locator_control_code <> 1;
Line: 293

SELECT i.item_no, l.lot_no, l.sublot_no, inv.whse_code, inv.location,
    inv.loct_onhand, inv.loct_onhand2
FROM ic_loct_inv inv,
    ic_item_mst_b i,
    ic_lots_mst l
WHERE
    inv.item_id = i.item_id AND
    inv.item_id = l.item_id AND
    inv.lot_id = l.lot_id AND
    ROUND(loct_onhand, 5) <> 0 AND
    DECODE(i.dualum_ind, 0, 99999, ROUND(loct_onhand2, 5)) <> 0 AND
    loct_onhand < 0 AND
    DECODE(i.dualum_ind, 0, 99999, loct_onhand2) < 0;
Line: 308

SELECT i.item_no, l.lot_no, l.sublot_no, inv.whse_code, inv.location,
    inv.loct_onhand, inv.loct_onhand2
FROM ic_loct_inv inv,
    ic_item_mst_b i,
    ic_lots_mst l
WHERE
    inv.item_id = i.item_id AND
    inv.item_id = l.item_id AND
    inv.lot_id = l.lot_id AND
    ROUND(loct_onhand, 5) <> 0 AND
    ROUND(loct_onhand2, 5) <> 0 AND
    i.dualum_ind <> 0 AND
    loct_onhand/ABS(loct_onhand) <> loct_onhand2/ABS(loct_onhand2);
Line: 323

SELECT i.item_no, l.lot_no, l.sublot_no, inv.whse_code, inv.location,
    inv.loct_onhand, inv.loct_onhand2
FROM ic_loct_inv inv,
    ic_item_mst_b i,
    ic_lots_mst l
WHERE
    inv.item_id = i.item_id AND
    inv.item_id = l.item_id AND
    inv.lot_id = l.lot_id AND
    ROUND(loct_onhand, 5) = 0 AND
    DECODE(i.dualum_ind, 0, 99999, ROUND(loct_onhand2, 5)) = 0 AND
    (loct_onhand <> 0 OR loct_onhand2 <> 0);
Line: 337

SELECT i.item_no, l.lot_no, l.sublot_no, inv.whse_code, inv.location,
    inv.loct_onhand, inv.loct_onhand2
FROM ic_loct_inv inv,
    ic_item_mst_b i,
    ic_lots_mst l
WHERE
    inv.item_id = i.item_id AND
    i.noninv_ind = 1 AND
    inv.item_id = l.item_id AND
    inv.lot_id = l.lot_id AND
    ROUND(loct_onhand, 5) <> 0 ;
Line: 350

select orgn_code, transfer_no
from ic_xfer_mst
WHERE
    transfer_status = 2 AND
    delete_mark = 0;