On Sat, Oct 20, 2001 at 01:11:30PM -0700, Mike E wrote:
>
> I've been having this debate in my mind and alternated my method on
> the past few projects I've worked on, and now I ask you, the MySQL
> community.
> 
> What is the best way to have a preferences table?
> 
> Here's what I've been doing:
> 
> Table preferences
> basepath varchar(255)
> adminemail varchar(255)
> 
> and on and on, a different field for each variable I want stored. 
> Alternatively:
> 
> Table preferences
> key varchar(255)
> value text
> 
> With a different row for each variable. This is much more dynamic,
> but is it worth the extra coding?

Yes, normalizing your data is almost always worth it.  Consider what
happens when you need to add two new fields, or remove one.

Jeremy
-- 
Jeremy D. Zawodny, <[EMAIL PROTECTED]>
Technical Yahoo - Yahoo Finance
Desk: (408) 349-7878   Fax: (408) 349-5454   Cell: (408) 685-5936

MySQL 3.23.41-max: up 45 days, processed 999,890,411 queries (252/sec. avg)

---------------------------------------------------------------------
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

Reply via email to