0
SELECT ma_forum.*, ma_forum_cat.*
FROM ma_forum, ma_forum_cat
JOIN ma_forum_comentarios ON ma_forum_comentarios.not_id = ma_forum.not_id
WHERE ma_forum.notcat_id=ma_forum_cat.notcat_id AND ma_forum.notcat_id='".$notcat_id."'
AND ma_forum.not_status='Ativo'
GROUP BY ma_forum.not_id
ORDER BY MAX(ma_forum_comentarios.comnot_data) DESC
未知列在「上子句」MySQL錯誤最大正每組
該列在表別名'ma_forum'表示的表中不存在。除此之外,沒有任何信息可以幫助您。 –
停止混合隱式(逗號分隔表)和顯式連接。你使用兩個內部連接,所以使用兩個適當的'JOIN'並從WHERE子句中刪除第一個隱式連接條件。 –
這是你的其他問題的重複。同一主題。 http://stackoverflow.com/questions/12555413/order-by-in-other-table#comment16910497_12555413 – ApplePie