可有人請告訴我如何解決這個查詢到它的工作,這樣我就不會收到錯誤消息:#1066 - 不唯一的表/別名:「personal_mem」SQL錯誤 - 不是唯一的表
SELECT personal_mem.id_mem, personal_mem.fn, personal_mem.ln, personal_mem.email, personal_mem.organisation, personal_mem.city, personal_mem.state, personal_mem.postcode, members.type, members.paid_to_date, members.username, payments_mem.payment_type
FROM `personal_mem`
LEFT JOIN personal_mem ON members.id_mem = personal_mem.id_mem
LEFT JOIN payments_mem ON members.id_mem = payments_mem.id_mem
WHERE members.paid_to_date > 1369922400 AND payments_mem.confirmed != 'TRUE'
ORDER BY payments_mem.payment_type
用'FROM members'替換'FROM personal_mem'# –
使用不同的別名多次連接同一個表,where子句中的'members'表在哪裏。 –