什么;我的查询错了......
我收到错误消息#1064 - 您的SQL语法出错了;检查与您的MySQL服务器版本对应的手册,以便在'附近使用正确的语法。 mail_time FROM ibc_messages m,ibc_msg_queue q AND m。 id = q。 msgstr和q'在第1行
SELECT distinct q.msgid, q.mail_time, m.status,
FROM ibc_msg_queue q , ibc_messages m
WHERE q.mail_time = '0000-00-00 00:00:00' AND q.msgid = m.id
ORDER BY q.msgid
答案 0 :(得分:3)
删除第三列后的逗号
SELECT distinct q.msgid , q.mail_time,m.status FROM
答案 1 :(得分:2)
在“FROM”子句
之前有一个额外的逗号答案 2 :(得分:1)
您的,
关键字前面有一个冗余逗号(FROM
)。只需删除它,你就可以了:
SELECT distinct q.msgid , q.mail_time,m.status
FROM ibc_msg_queue q , ibc_messages m
WHERE q.mail_time = '0000-00-00 00:00:00' AND q.msgid = m.id ORDER BY q.msgid
答案 3 :(得分:1)
你有一个额外的逗号:
YOURS:
SELECT distinct q.msgid ,
q.mail_time,
m.status,
FROM ibc_msg_queue q , ibc_messages m
WHERE q.mail_time = '0000-00-00 00:00:00'
AND q.msgid = m.id
ORDER BY q.msgid