David T-G wrote:
You're thinking of ENUMs. SETs are for when you want multiple things selected out of a list. So perhaps, favorite colours:I'm still trying to get a good handle on how sets can be useful to me.
You have a column Colours SET('black','purple','blue','green','yellow','orange','red','white');
Then you can do a query like:
UPDATE FavoriteColours SET Colours = ('yellow','blue','green') WHERE ID = 4;
(The 'SET' keyword in the UPDATE command is purely coincidental)
Anyhow, ENUMs are the same as having a second table with a foreign key relation to the current table and SETs are the same as having a table that you double-join against to match up multiple values.
PS 'same' here means it has pretty much the same functionality as ...
--
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php