Query to find valid categories in a Category Set:
SELECT mc.concatenated_segments,mc.description
FROM apps.mtl_category_set_valid_cats mcsvc
,apps.mtl_category_sets mcs
,apps.mtl_categories_kfv mc
WHERE mcsvc.category_set_id = mcs.category_set_id
AND mc.category_id = mcsvc.category_id
AND mcs.category_set_name = '<category_set_name>';
Query to find manufacturer part number for an item:
SELECT mm.manufacturer_name,
mp.mfg_part_num,
mp.description,
msi.segment1 inv_item,
msi.description item_desc,
mp.approval_status
FROM apps.mtl_system_items msi,
apps.mtl_mfg_part_numbers mp,
apps.mtl_manufacturers mm,
apps.org_organization_definitions o
WHERE mm.manufacturer_id = mp.manufacturer_id
AND mp.inventory_item_id = msi.inventory_item_id
AND mp.organization_id = msi.organization_id
AND msi.segment1 = '<item_number>'
AND msi.organization_id = o.organization_id
AND o.organization_code = '<org_code>';
SELECT mc.concatenated_segments,mc.description
FROM apps.mtl_category_set_valid_cats mcsvc
,apps.mtl_category_sets mcs
,apps.mtl_categories_kfv mc
WHERE mcsvc.category_set_id = mcs.category_set_id
AND mc.category_id = mcsvc.category_id
AND mcs.category_set_name = '<category_set_name>';
Query to find manufacturer part number for an item:
SELECT mm.manufacturer_name,
mp.mfg_part_num,
mp.description,
msi.segment1 inv_item,
msi.description item_desc,
mp.approval_status
FROM apps.mtl_system_items msi,
apps.mtl_mfg_part_numbers mp,
apps.mtl_manufacturers mm,
apps.org_organization_definitions o
WHERE mm.manufacturer_id = mp.manufacturer_id
AND mp.inventory_item_id = msi.inventory_item_id
AND mp.organization_id = msi.organization_id
AND msi.segment1 = '<item_number>'
AND msi.organization_id = o.organization_id
AND o.organization_code = '<org_code>';
Thank you .. it was very helpful information
ReplyDelete