SELECT sum(1) AS GP
FROM [SELECT A.BSC,A.BTS,SUM(TCH) AS PDTCH,B.CDED,B.CDEF FROM
TRXPAR A,BTSPAR B
WHERE
A.BSC=B.BSC
AND int(right(A.BTS,4))=int(B.BTS)
AND A.GTRX="Y"
GROUP BY A.BSC,A.BTS,B.CDED,B.CDEF]. AS [%$##@_Alias]
WHERE ((([PDTCH]*[CDED])<100 And ([PDTCH]*[CDED])>0));
原帖由 closeyoureyes 于 2007-8-3 10:16 发表
SELECT sum(1) AS GP
FROM [SELECT A.BSC,A.BTS,SUM(TCH) AS PDTCH,B.CDED,B.CDEF FROM
TRXPAR A,BTSPAR B
WHERE
A.BSC=B.BSC
AND int(right(A.BTS,4))=int(B.BTS)
AND A.GTRX="Y"
GROUP BY A.B ...
sum(1)应该是用SQL进行自动编号------------------------------------------------------这个说法有什么帮助文件可以查阅么?
这个句子本身是将满足[PDTCH]*[CDED]<100 And [PDTCH]*[CDED])>0条件的纪录输出,但在sum的语法里没有讲解1这个变量的解释,求解!