@Hawkee i don't know if i mentioned this before, i'm interesting to create an Inbox Function on my Site, like Facebook Style. Conversation Style. At first i thought that i must have 1 database Inbox, with columns: message_id , sender_id , recipient_id , is_message_read(bool), read_date , message_content , date_in_unix_time_message_sent
and to process these first with A SQL Query with "LIMIT" for example the 20 first messages... Filtered by date_in_unix_time_message_sent...
But then i faced a dificulty. How i was supposed to get a number of users sent message with LIMIT without getting the messages of the 1 of the conversation. I mean Lets say i messaged with a user last time 20 messages, and if i want to take for example Messages with the Last 20 users... how i was supposed to take that data, I had to parse with this table ALL The SQL Table [damn a lot of process time] and then with loops to group them.
So have you any idea how to achieve this?
Why not add a parent_message_id field to designate children messages under a thread. That way you can pull unique conversations by selecting those without a parent.