Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2010

    Unanswered: Database design help

    I am building a site where people can post items for sale in different groups (Clubs, organizations, etc). On the main page they will search for their group and when they select it, it will take them to the group portal which displays the items specifically posted to that group. If their group isn't there, then they can add it.

    I am pretty new to MySQL. All i could think of doing for when people add their group is...

    1. Create a table for the groups info and assign the name, id, etc.
    2. Automatically create a new table called group[id]. I then can get the ID from querying the NAME and then access the group[id] table with posts. This way of doing it is extremely limited and cluttery... My database is looking like

    Does anyone have any suggestions?

  2. #2
    Join Date
    Apr 2002
    Toronto, Canada
    Quote Originally Posted by Pspeters View Post
    This way of doing it is extremely limited and cluttery...
    i can definitely confirm that

    a table for groups is fine

    the other table would hold items for all groups, with a foreign key for the group that each item belongs to | @rudydotca
    Buy my SitePoint book: Simply SQL

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts