我的SQL语句有点问题。这有点难以解释所以我会告诉你:
SELECT exp_channel_data.field_id_102,
exp_channel_data.field_id_104,
exp_channel_data.field_id_126,
exp_channels.deft_status
FROM exp_channel_data
INNER JOIN exp_channels
ON exp_channels.channel_id = exp_channel_data.channel_id
INNER JOIN exp_channel_titles
ON exp_channels.channel_id = exp_channel_titles.channel_id
WHERE exp_channels.channel_id = 18
AND exp_channel_titles.channel_id = 19
不起作用的位是AND exp_channel_titles.channel_id = 19
有关如何解决此问题的任何想法?
提前致谢!
答案 0 :(得分:6)
您已加入exp_channels.channel_id = exp_channel_titles.channel_id
并正在过滤
exp_channels.channel_id = 18
exp_channel_titles.channel_id = 19
所以永远不会有任何结果