Logo Go / Tiger Hareketsiz Carileri Kullanımdışı yapma

Logo Go / Tiger Hareketsiz Carileri Kullanımdışı yapma


with bb as (SELECT LOGICALREF,CODE, DEFINITION_,( select count (CLIENTREF) from dbo.LV_115_01_CLEKSTRE where 

CLIENTREF = aa.LOGICALREF ) as say FROM dbo.LG_115_CLCARD as aa with (nolock) where CARDTYPE = 3 )

update LG_115_CLCARD set ACTIVE = 1 where LOGICALREF in ( select LOGICALREF from bb where say = 0)


Logo Tiger Depo Bazında Malzeme/Stok Durumları

Malzemlerin listesini depo bazında almak isterseniz aşağıdaki kodu kullanabilirsiniz.

SELECT     ITEMS.CODE, ITEMS.NAME, STINVTOT.INVENNO AS DEPO, SUM(STINVTOT.ONHAND) AS MIKTAR
FROM         LV_001_02_STINVTOT AS STINVTOT LEFT OUTER JOIN
LG_001_ITEMS AS ITEMS ON STINVTOT.STOCKREF = ITEMS.LOGICALREF
WHERE     (ITEMS.CARDTYPE = 1) AND STINVTOT.INVENNO = -1 /* Tüm Depolar için -1 */
GROUP BY ITEMS.CODE, ITEMS.NAME, STINVTOT.INVENNO, ITEMS.CARDTYPE
HAVING      (SUM(STINVTOT.ONHAND) <> 0)