Eric,

You do not want to encode data in table names. Mainly you want to create the least redundant set representation of your data, realise that representation as fixed related tables, then use SQL to fill & query those tables. Do a little reading and play with a few toy designs before you start on your own problem.

Two of those Codd's Rules sites have gone away but there are loads of them on the web, eg it took a few secs to find
  http://www.itworld.com/nl/db_mgr/05072001/
  http://members.aol.com/mbtexts/120.html
and the rules are covered too in http://www.artfulsoftware.com/mysqlbook/sampler/mysqled1ch01.pdf.

PB



Eric Gorr wrote:
Peter Brawley wrote:
Eric,

If I understand you correctly, you propose to encode user and group info as table names. That's a mistake. To use an RDBMS like MySQL effectively, you want to encode your information as rows of data in tables whose names and structures do not vary.

Thank you for your comments. Would this design be better?

( assume that one of the group names will be 'Group_A' )

Database

  Table_Groups
    group name
    # of user columns

  Table_Group_A_users
    username
    Column 1 Data
    Column 2 Data
    ...
    Column N Data

I am still encoding group info into a table name, but I am unsure of how to avoid this and not have a table with a lot of wasted space.

May I suggest you read some of the tutorials listed at http://www.artfulsoftware.com/dbresources.html, and/or read http://www.artfulsoftware.com/mysqlbook/sampler/mysqled1ch01.pdf.

Thank you for the pointers.

Unfortunately, http://www.artfulsoftware.com/dbresources.html seems to have a couple of broken links (Codd's Rules)...any idea where this information can be found?