Unique id + semi unique thread_id column.
Posted: Fri Oct 19, 2007 3:33 am
Hi!
I'm trying to create a messaging system for a project I'm working on.
Theoretically I only need one table to do this, but I do need a unique auto increment primary key 'id' and a thread_id column.
The thread_id column will contain a unique value for new messages, and will contain referential values for thread replies (children)..
What is the best way of accomplishing this or should I just create a thread table with just one column?
So to recap I need standard id, plus a thread_id that will be unique for new threads and referential for replies.
Thanks!
I'm trying to create a messaging system for a project I'm working on.
Theoretically I only need one table to do this, but I do need a unique auto increment primary key 'id' and a thread_id column.
The thread_id column will contain a unique value for new messages, and will contain referential values for thread replies (children)..
What is the best way of accomplishing this or should I just create a thread table with just one column?
So to recap I need standard id, plus a thread_id that will be unique for new threads and referential for replies.
Thanks!