Yes, in some cases. It's called Normalization.

Although normalization is good practice, it can complicate queries.

Have you thought about storing just M/T/W/etc and then storing the Opening, Closing times as a comma delimited string? Maybe like

Monday: 11AM,1PM,5PM,1AM
Tuesday 10AM,1PM,6PM,12AM

You'll only need 7 fields.

OR, you can reduce it further and only have 3 Fields. Morning, Afternoon, Night. Then you can store all times for the week into one string.


At 03:26 AM 12/6/2002 +0100, Alliax you wrote:
Thank you for this and for the previous answer about create temporary table,

your RestTimes is a nice way to do it, but it multiplies the number of rows
of the table.
So you say it's better to have more rows than have less row, when doing
simple select query?
I'll do it your way then, except if somebody has a better idea ?
--
Michael She  : [EMAIL PROTECTED]
Mobile       : (519) 589-7309
WWW Homepage : http://www.binaryio.com/



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