SELECT distinct a.uiorderid, a.orderid, a.liveindate, a.leavedate, a.ordertype, a.status, a.ordertime,
b.hotelid, b.hotelname, b.contactman AS affirmman, b.contactfax AS affirmfax, b.re, b.verifystatus,
c.guestname, c.contactphone AS guestcontphone, c.contactname AS guestcontman, d.contactphone
AS affirmphone, e.operatorname, f.membercode, 1 as querytype, g.notifyway, g.notidest, g.notiphone,
g.status AS notifystatus, g.contsample, g.emailaddr, g.notifytime FROM HTL_R_ORDERBASE a,
HTL_R_ORDERHOTEL b, HTL_R_ORDERGUEST c, HTL_I_AFFIRM d, O_OPERATOR e, M_MEMBER f,
HTL_R_NOTIFYCONTENT g WHERE 1 = 1 AND a.orderid = b.orderid AND a.orderid = c.orderid
AND a.orderid = g.orderid AND b.hotelid = d.hotelid AND a.memberid = f.memberid
AND UPPER (a.orderopercd) = UPPER (e.operatorcd) AND g.notiDest = 0 AND g.status = 0
AND mod( a.orderid,10 ) in (0,1,2,3,4,5,6,7,8,9) AND a.orderopercd like 'csr0000'
order by a.liveindate 查出来9条,在dbgrid中只显示8条,为什么呢
b.hotelid, b.hotelname, b.contactman AS affirmman, b.contactfax AS affirmfax, b.re, b.verifystatus,
c.guestname, c.contactphone AS guestcontphone, c.contactname AS guestcontman, d.contactphone
AS affirmphone, e.operatorname, f.membercode, 1 as querytype, g.notifyway, g.notidest, g.notiphone,
g.status AS notifystatus, g.contsample, g.emailaddr, g.notifytime FROM HTL_R_ORDERBASE a,
HTL_R_ORDERHOTEL b, HTL_R_ORDERGUEST c, HTL_I_AFFIRM d, O_OPERATOR e, M_MEMBER f,
HTL_R_NOTIFYCONTENT g WHERE 1 = 1 AND a.orderid = b.orderid AND a.orderid = c.orderid
AND a.orderid = g.orderid AND b.hotelid = d.hotelid AND a.memberid = f.memberid
AND UPPER (a.orderopercd) = UPPER (e.operatorcd) AND g.notiDest = 0 AND g.status = 0
AND mod( a.orderid,10 ) in (0,1,2,3,4,5,6,7,8,9) AND a.orderopercd like 'csr0000'
order by a.liveindate 查出来9条,在dbgrid中只显示8条,为什么呢
另外,查一下与数据有关控件的事件,看看是否有过滤记录的语句
你不如用bde/odbc/dbexpress,再好用odac
如果你一定要用ado,注意两点
1.要用oracle provider for ole db而不要用Microsoft OLE DB Provider for oracle
2.升级你的mdac到2.7以上