Can someone share me the sql query to fetch item information from sales order lines table
can someone share me the sql query to get item information from sales order lines table. I have the following sql but it runs for a long time without any results.
select 'Specific'
,msib.segment1
,msib.item_type
,msib.inventory_item_status_code
,msib.inventory_item_id
,msib.organization_id
from apps.mtl_system_items_b msib
where organization_id = /*Master Org ID */ 102
and inventory_item_status_code <> 'Obsolete'
and item_type = 'FG'
and EXISTS(SELECT 1
FROM apps.oe_order_lines_all ool
,apps.oe_Transaction_types_All ottt
,apps.oe_order_headers_All ooh
WHERE ottt.transaction_type_id = ooh.ordeR_type_id