SELECT
  ITEMNMBR AS itemnmbr,
  LOCNCODE AS locncode,
  BINNMBR AS binnmbr,
  RCRDTYPE AS rcrdtype,
  PRIMVNDR AS primvndr,
  ITMFRFLG AS itmfrflg,
  BGNGQTY AS bgngqty,
  LSORDQTY AS lsordqty,
  LRCPTQTY AS lrcptqty,
  LSTORDDT AS lstorddt,
  LSORDVND AS lsordvnd,
  LSRCPTDT AS lsrcptdt,
  QTYRQSTN AS qtyrqstn,
  QTYONORD AS qtyonord,
  QTYBKORD AS qtybkord,
  QTY_Drop_Shipped AS qty_drop_shipped,
  QTYINUSE AS qtyinuse,
  QTYINSVC AS qtyinsvc,
  QTYRTRND AS qtyrtrnd,
  QTYDMGED AS qtydmged,
  QTYONHND AS qtyonhnd,
  ATYALLOC AS atyalloc,
  QTYCOMTD AS qtycomtd,
  QTYSOLD AS qtysold,
  NXTCNTDT AS nxtcntdt,
  NXTCNTTM AS nxtcnttm,
  LSTCNTDT AS lstcntdt,
  LSTCNTTM AS lstcnttm,
  STCKCNTINTRVL AS stckcntintrvl,
  Landed_Cost_Group_ID AS landed_cost_group_id,
  BUYERID AS buyerid,
  PLANNERID AS plannerid,
  ORDERPOLICY AS orderpolicy,
  FXDORDRQTY AS fxdordrqty,
  ORDRPNTQTY AS ordrpntqty,
  NMBROFDYS AS nmbrofdys,
  MNMMORDRQTY AS mnmmordrqty,
  MXMMORDRQTY AS mxmmordrqty,
  ORDERMULTIPLE AS ordermultiple,
  REPLENISHMENTMETHOD AS replenishmentmethod,
  SHRINKAGEFACTOR AS shrinkagefactor,
  PRCHSNGLDTM AS prchsngldtm,
  MNFCTRNGFXDLDTM AS mnfctrngfxdldtm,
  MNFCTRNGVRBLLDTM AS mnfctrngvrblldtm,
  STAGINGLDTME AS stagingldtme,
  PLNNNGTMFNCDYS AS plnnngtmfncdys,
  DMNDTMFNCPRDS AS dmndtmfncprds,
  INCLDDINPLNNNG AS inclddinplnnng,
  CALCULATEATP AS calculateatp,
  AUTOCHKATP AS autochkatp,
  PLNFNLPAB AS plnfnlpab,
  FRCSTCNSMPTNPRD AS frcstcnsmptnprd,
  ORDRUPTOLVL AS ordruptolvl,
  SFTYSTCKQTY AS sftystckqty,
  REORDERVARIANCE AS reordervariance,
  PORECEIPTBIN AS poreceiptbin,
  PORETRNBIN AS poretrnbin,
  SOFULFILLMENTBIN AS sofulfillmentbin,
  SORETURNBIN AS soreturnbin,
  BOMRCPTBIN AS bomrcptbin,
  MATERIALISSUEBIN AS materialissuebin,
  MORECEIPTBIN AS moreceiptbin,
  REPAIRISSUESBIN AS repairissuesbin,
  ReplenishmentLevel AS replenishmentlevel,
  POPOrderMethod AS popordermethod,
  MasterLocationCode AS masterlocationcode,
  POPVendorSelection AS popvendorselection,
  POPPricingSelection AS poppricingselection,
  PurchasePrice AS purchaseprice,
  IncludeAllocations AS includeallocations,
  IncludeBackorders AS includebackorders,
  IncludeRequisitions AS includerequisitions,
  PICKTICKETITEMOPT AS pickticketitemopt,
  INCLDMRPMOVEIN AS incldmrpmovein,
  INCLDMRPMOVEOUT AS incldmrpmoveout,
  INCLDMRPCANCEL AS incldmrpcancel,
  Move_Out_Fence AS move_out_fence,
  INACTIVE AS inactive,
  DEX_ROW_ID AS dex_row_id
FROM [GPSERVER].[CHG].[dbo].[IV00102]
WHERE QTYONHND <> 0
  
