SELECT * FROM himc_chat_d WHERE chat_no IN ( SELECT chat_no FROM himc_chat_m WHERE TIMESTAMP (assign_dtm) BETWEEN '2020-04-02 00:00:00' AND '2020-04-02 23:00:00' AND staff_no = '410651' )
报错信息:
[Err] 1064 - invalid route in sql, multi tables found but datanode has no intersection
SELECT *
FROM himc_chat_d a
INNER JOIN
(SELECT chat_no
FROM himc_chat_m
WHERE TIMESTAMP(assign_dtm) BETWEEN '2020-04-02 00:00:00' AND '2020-04-02 23:00:00'
AND staff_no = '410651' ) b
ON a.chat_no = b.chat_no