If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > Database design questions

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 02-22-09, 21:15
toxi toxi is offline
Registered User
 
Join Date: Mar 2004
Posts: 16
Database design questions

Hi everyone, I need some help with a project I have to do...

I'm still in the process of designing the database, which involves allowing users to book a certain lane in a swimming pool. I came up with some tables but I dont know if they make sense. Any help is appreciated:

Tables

Pool, Bookings, Accounts, Lanes.

However, I feel that lanes is kind of not needed. Do you think I'm getting it much too complicated where it can be done with about 2 entities? There won't be certain people booking, just a few standardized groups.

thank you
Reply With Quote
  #2 (permalink)  
Old 02-22-09, 23:03
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,524
how would you know which lanes can be booked if there wasn't a table listing the lanes that can be booked?
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
  #3 (permalink)  
Old 02-23-09, 04:57
toxi toxi is offline
Registered User
 
Join Date: Mar 2004
Posts: 16
i suppose this makes some sense, but I guess I will only have a lookup query to get the available lanes from the "lane" table, right ?
Reply With Quote
  #4 (permalink)  
Old 02-23-09, 05:00
pootle flump pootle flump is offline
King of Understatement
 
Join Date: Feb 2004
Location: One Flump in One Place
Posts: 14,905
Quote:
Originally Posted by toxi
I guess I will only have a lookup query to get the available lanes from the "lane" table, right ?
Yah. Which would be mighty tricky if you followed this line of thinking:
Quote:
Originally Posted by toxi
However, I feel that lanes is kind of not needed.
This is why Rudy was questioning you.
__________________
Testimonial:
Quote:
pootle flump
ur codings are working excelent.
Reply With Quote
  #5 (permalink)  
Old 02-23-09, 05:17
toxi toxi is offline
Registered User
 
Join Date: Mar 2004
Posts: 16
I was trying to elaborate and express my concerns because at the beginning it didn't seem to make much sense! Now I kind of get it, thanks!
Reply With Quote
  #6 (permalink)  
Old 02-23-09, 07:18
toxi toxi is offline
Registered User
 
Join Date: Mar 2004
Posts: 16
You reckon it'll also be useful if I add a "Days" table ?
Reply With Quote
  #7 (permalink)  
Old 02-23-09, 07:33
pootle flump pootle flump is offline
King of Understatement
 
Join Date: Feb 2004
Location: One Flump in One Place
Posts: 14,905
I'll leave this one to Rudy - he loves this question
__________________
Testimonial:
Quote:
pootle flump
ur codings are working excelent.
Reply With Quote
  #8 (permalink)  
Old 02-23-09, 07:44
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,524
thanks poots

no, toxi, you don't need a Days table -- unless you specifically have certain days where no lanes can be booked, and these days cannot be predetermined through a simple formula (e.g. closed on statutory holidays)

__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
  #9 (permalink)  
Old 02-23-09, 10:31
toxi toxi is offline
Registered User
 
Join Date: Mar 2004
Posts: 16
Ok, now I've just received a revised spec, where on some periods of some days [standard], the pool will be closed.

I guess this may as well fit in the bookings table
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On