I'd like to program my own forum for learning purposes and I need some help in planing database structure.
I want to achieve following task:
- I want to store members in database
- Each user can create new threads
- Each thread can be commented by every member
My own approach would be...
- Table for members
- Table for threads
- When user creates new thread, system dinamicly creates new table COMMENTS_THREAD_ID and all comments associated with this thread would be included in this table
Is it good practice to create separate table for comments for each thread? What if site would get popular and there would be thousands of threads daily? Could you suggest structure that would suite this type of scenario?
Thanks