I want to design a database for lots of users. Each user will be managing
their own messages. Does it make sense to create a table for each user after
they've registered?
Or should I just create one MESSAGES table and store messages there keyed off
of their user_id?
If I create a table for
One table,
USERS
Another table
MESSAGES
With a foreign key referencing users.
Maybe a second foreign key referencing the destinating user as well.
-Original Message-
From: James Tu [mailto:[EMAIL PROTECTED]
Sent: Monday, August 07, 2006 1:56 PM
To: mysql@lists.mysql.com
Subject:
Thanks everyone.
Now I feel confident that one table will be fine (Tripp's stat of 30
million records put me at ease :) ).
Cheers,
-James
On Aug 7, 2006, at 4:08 PM, John Meyer wrote:
One table,
USERS
Another table
MESSAGES
With a foreign key referencing users.
Maybe a second foreign key
@lists.mysql.com
Sent: Monday, August 07, 2006 4:11 PM
Subject: Re: Database design question
Thanks everyone.
Now I feel confident that one table will be fine (Tripp's stat of
30 million records put me at ease :) ).
Cheers,
-James
On Aug 7, 2006, at 4:08 PM, John Meyer wrote:
One table,
USERS
On 8/7/06, James Tu [EMAIL PROTECTED] wrote:
If I create a table for each user (I can potentially have hundreds of
thousands of users), will MySQL be able to handle this?
If I just have one table, I could potentially have millions of
records in one table. Will MySQL be able to handle this?
james tu [EMAIL PROTECTED] wrote on 04/26/2005 12:06:34 PM:
I have four different activities. Each has its own set of data that
I want to save. So, I made four different tables to hold the saved
data. Each record also has 'keywords' field (essentially this is the
only field that all
I tried that and maybe I'm doing something wrong but...
-I have to select the same number of columns...for each UNION
-And each of the records from the union fall under the same column
headings as the first SELECT...
I even tried to define column aliases..
SELECT `running` as `running_blah`...
If you posted your actual table structures (SHOW CREATE TABLE xx\G) I
think I could be more helpful. Right now I am just shooting in the dark.
Shawn Green
Database Administrator
Unimin Corporation - Spruce Pine
James [EMAIL PROTECTED] wrote on 04/26/2005 02:15:49 PM:
I tried that and
I haven't created real project tables yet.
But here are the test ones that I'm experimenting with.
CREATE TABLE east (
id int(11) NOT NULL auto_increment,
keywords varchar(255) default NULL,
east_1 varchar(255) default NULL,
PRIMARY KEY (id)
) ;
CREATE TABLE north (
north_id int(11) NOT
Mahmoud,
Are these values atomical?
My other question is what are the repercussions of
not putting a table in 2nd and 3rd Normal Form.
Your 'choice1-subchoice1' etc are combined values, so they aren't
atomic. From your three example dropdown values, it looks as if
'choice' and 'subchoice'
JOHN MEYER [EMAIL PROTECTED] wrote on 07/04/2004 15:39:10:
Hi,
I'm writing a database for an online candle store. Here's the
situation. This store sells all sorts of items including candles.
Now the gist is that some of the candles can be made in different
types of waxes and some
Everything I've read about creating online stores is that you are
selling inventory items, not the items that makeup the inventory item.
So if you sell a red candle made from wax X, candle is the product and
red wax X are two attributes of the product.
Ideally your structure would work for any
I'm not 100% sure as to what you are trying to do, however, the relationship
you describe could, I believe, be modeled as:
Candles (candleid, description, price)
Waxes (waxid, name/description)
Candle_Waxes (candleid, waxid)
Thus one table holds the description and price of each candle, another
[snip]
Let's say that I have users Mary, Joe, Frank, and Dan. I also have
servers panther, cheetah, jaguar and lion. The data for each account that I
want to maintain is UID, GID, home directory, and default shell.
In designing a table or tables to handle this example what can I
make as a
On 18-Jun-2003 NIPP, SCOTT V (SBCSI) wrote:
Hello... I am currently working on a User Account Management
system. I am actually a Unix SA who is moonlighting at work as a MySQL
DBA and web developer. I am learning a lot and enjoying the work, but I
am
severely lacking in database
On 3/28/02 1:39 PM [EMAIL PROTECTED] wrote:
What I want to do is have a database that keeps track of large distribution
lists. Each list has a unique ID, an owner (which is a reference to an ID in
another table) and a creation date.
My question is this: Would it be more efficient to have
-Original Message-
From: Ben Holness [mailto:[EMAIL PROTECTED]]On Behalf Of
[EMAIL PROTECTED]
...
My question is this: Would it be more efficient to have each entry in the
list stored in this table in the database, or would I be better
off having a
reference to a file that is
Hi Ben:
Performance would definitely be better if you store the data in the
database as opposed to simply storing references to files. Sounds like you
could solve this with 2 tables with one for the actual lists (assuming the
structure of all your list is the same) and the other for the list
Hi Chris/Nick/Scalper,
Thanks for the replies. I am not too sure how to implement this in tables,
so I will give an example:
Let's say I have three lists - a,b and c. List a contains 10,000 entries,
list b contains 2,500 entries and list c contains 75,000 entries.
I have a table of lists, with
In your situation (or any situation, IMHO),
multi-value fields defeat the purpose of good database
design.
I think you are on the right track if you are willing
to tolerate a little redundancy for the sake of
simplicity (as a one-to-many relationship). If you
really want to structure it as a
Nick,
This is pretty familiar to me because I'm analyzing the behavior of
people
in on-line discussions, so I'm gathering such data.
Which begs the questions:
- in what way are you analyzing behavior? and
- in what way are you analyzing this list-community?
=dn
MySQL list busting
-Original Message-
From: DL Neil [mailto:[EMAIL PROTECTED]]
...
Which begs the questions:
- in what way are you analyzing behavior? and
- in what way are you analyzing this list-community?
There's too much to read, is the simple answer to the first question.
Over the last few
Thanks very much to every who helped me with my MySQL problem!
I will probably go with the three table solution as it also eliminates the
need for yet another table!
Cheers,
Ben
-
Before posting, please check:
On Saturday 28 July 2001 15:09, Scott Goldstein wrote:
I'm new to MySQL and database design and I have a questions concerning
entities with common attributes.
Suppose I have two entities, foo and bar with the following attributes:
foo: (id, A, B, C, D, F)
bar: (id, A, B, C, X, Y)
Well, I
24 matches
Mail list logo