我的查询如下:
SELECT DISTINCT(FldStrategyID), FldTradeServerName,FldBaseDir,FldBinaryStartTime
FROM TblOrders Ord,
(SELECT CONCAT(FldStrategyID,'.',FldTradeServerName,'.',FldBaseDir,'.',FldBinaryStartTime) strid
FROM TblOrders
GROUP BY FldStrategyID) as OrderView
WHERE Ord.FldStrategyID !=''
AND OrderView.strid NOT IN (SELECT FldStrategyID FROM TblStrategyMasters WHERE 1)
问题是这部分不起作用:
OrderView.strid NOT IN (SELECT FldStrategyID FROM TblStrategyMasters WHERE 1)
答案 0 :(得分:0)
我认为某些地方缺少引号(')。