So, I have this mysql query:
SELECT member_id, text FROM review WHERE text != "" ORDER BY date DESC LIMIT 2
This returns the latest two reviews, my question is can I somehow restrict this query returning two rows with the same member_id? I’ve tried adding DISTINCT before member_id but has no effect.
You can use group by. But if you have more than two rows for the same id, you cannot know which text will come.