SELECT LG_XXX_ITEMS.CODE AS 'Mamul Kod', LG_XXX_ITEMS.NAME AS 'Mamul Adı', LG_XXX_PRCLIST.PRICE AS 'Fiyat', LG_XXX_PRCLIST.PTYPE AS '1 Alış - 2 Satış', LG_XXX_PRCLIST.BEGDATE AS 'Fiyat Başlangıcı', LG_XXX_PRCLIST.ENDDATE AS 'Fiyat Geçerlilik', LG_XXX_ITEMS.VAT AS 'Ürün Kdv'
FROM {oj DBADI.dbo.LG_XXX_ITEMS LG_XXX_ITEMS LEFT OUTER JOIN DBADI.dbo.LG_XXX_PRCLIST LG_XXX_PRCLIST ON LG_XXX_ITEMS.LOGICALREF = LG_XXX_PRCLIST.CARDREF}
WHERE (LG_XXX_PRCLIST.ACTIVE=0)