rbk333(提问者) 回复 用户E2976026时间关联那里有问题。 我是这么写的,少套了1层
SELECT * FROM
(SELECT DISTINCT CALDAY,COUNT(EMPLOYEE),ZICZG0010
FROM \"_SYS_BIC\".\"CB.BL.YW/ZBL_ZDEYG001\"
GROUP BY CALDAY,ZICZG0010) B
RIGHT JOIN \"_SYS_BIC\".\"ZBMJJB_BM\" A
ON A.BMZH=B.ZICZG0010
--AND A.NY=CONCAT(LEFT(B.CALDAY,4),\'-\',RIGHT(B.CAKDAY,2)) (这行注释掉可以正常查询到)
WHERE A.BMZHMS=\'东安店\'