Results 1 to 9 of 9
  1. #1
    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

  2. #2
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    how would you know which lanes can be booked if there wasn't a table listing the lanes that can be booked?
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  3. #3
    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 ?

  4. #4
    Join Date
    Feb 2004
    Location
    One Flump in One Place
    Posts
    14,912
    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:
    pootle flump
    ur codings are working excelent.

  5. #5
    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!

  6. #6
    Join Date
    Mar 2004
    Posts
    16
    You reckon it'll also be useful if I add a "Days" table ?

  7. #7
    Join Date
    Feb 2004
    Location
    One Flump in One Place
    Posts
    14,912
    I'll leave this one to Rudy - he loves this question
    Testimonial:
    pootle flump
    ur codings are working excelent.

  8. #8
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    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)

    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  9. #9
    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

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •