MySQL Forums
Forum List  »  Newbie

Re: database design
Posted by: Claude Martin
Date: April 05, 2005 12:34AM

you can create a new table that stores the drinks every user likes:
something like that:
CREATE TABLE `user_drinks` (
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT ,
`userid` INT UNSIGNED NOT NULL ,
`drinkid` INT UNSIGNED NOT NULL ,
PRIMARY KEY ( `id` ) ,
INDEX ( `userid` )
);

then you just save the id of a user and the id of a drink.

http://animalliberation.tk http://veganismus.ch
http://maqi.de http://tierrechtskochbuch.de

Options: ReplyQuote


Subject
Written By
Posted
April 05, 2005 12:15AM
Re: database design
April 05, 2005 12:34AM
April 05, 2005 08:32AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.