Senetleri çağırma işleminde SQL'i takip ettiğimde şöyle bir sonuç ile karşılaştım.
SELECT DISTINCT TOP 150
LGMAIN.LOGICALREF, LGMAIN.PORTFOYNO, LGMAIN.NEWSERINO, LGMAIN.DUEDATE, LGMAIN.BANKNAME, LGMAIN.OWING, LGMAIN.SETDATE, LGMAIN.DOC, LGMAIN.BRANCH,
LGMAIN.CURRSTAT, LGMAIN.CANCELLED, LGMAIN.DEVIR, LGMAIN.TRCURR, LGMAIN.TRNET, LGMAIN.AMOUNT, LGMAIN.REPORTNET, LGMAIN.LINEEXCTYP, LGMAIN.SPECODE,
LGMAIN.OPSTAT, LGMAIN.PROJECTREF, LGMAIN.AFFECTCOLLATRL, LGMAIN.AFFECTRISK, LGMAIN.USEGIRORATE, LGMAIN.GIROAMOUNT, LGMAIN.GIROREPNET, LGMAIN.USERAISEDVAL,
LGMAIN.RAISEDVALAMOUNT, PROJECT.CODE
FROM
LG_120_01_CSCARD LGMAIN WITH(NOLOCK)
LEFT OUTER JOIN LG_120_01_CSTRANS CQTRN WITH(NOLOCK) ON (LGMAIN.LOGICALREF = CQTRN.CSREF)
LEFT OUTER JOIN LG_120_PROJECT PROJECT WITH(NOLOCK) ON (LGMAIN.PROJECTREF = PROJECT.LOGICALREF)
WHERE
BU SORGU 2.69 DA VAR VE BU SORGU İLE SENETLERİ GETİRMİYOR
/*
(LGMAIN.DOC = 2) AND (LGMAIN.STATUS = 0) AND (LGMAIN.CANCELLED = 0) AND (LGMAIN.BRANCH = 1) AND
((CQTRN.STATNO = 2) AND (LGMAIN.CURRSTAT = 7) AND (CQTRN.STATUS IN (3,4) OR ((CQTRN.DEVIR = 1) AND (CQTRN.STATUS = 1) AND (LGMAIN.CURRSTAT <> 7 )))) AND (LGMAIN.OPSTAT IN (0, 2))
*/
BU SORGU 2.65 DE VAR BU SORGU İLE SENETLERİ GETİRİYOR
(LGMAIN.DOC = 2) AND (LGMAIN.STATUS = 0) AND (LGMAIN.CANCELLED = 0) AND (LGMAIN.BRANCH = 1) AND (LGMAIN.CURRSTAT IN (7,5,4,3)) AND (LGMAIN.OPSTAT IN (0, 2))
ORDER BY
LGMAIN.DOC DESC, LGMAIN.PORTFOYNO DESC, LGMAIN.LOGICALREF DESC
Bu durumla ilgili çözüm bulan varmıdır ?