Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2012
    Posts
    2

    Database design help needed please!

    Hey guys, I'm new to this forum so firstly hi, it's great to find such great place!

    So my issue is I'm trying to design a database system for a website I intend to implement, its for booking and viewing appointments, I've done a lot of work in terms of what I want it to do and have the knowledge to do it, I just want some input into my database design.

    Okay so I have 3 tables, membership, availability and appointments, heres what they look like so far:

    Membership table:

    MEMBER_ID
    FIRST_NAME
    SURNAME
    ROLE
    EMAIL
    EMAIL_ALT
    PHONE
    OFFICE

    Availability table:

    MEMBER_ID
    DATE
    TIME
    LOCATION
    STATUS
    AVAIL_ID

    Appointment table:

    MEMBER_ID
    DATE
    TIME
    LOCATION
    STATUS
    APP_ID
    AVAIL_ID


    The idea is that a member registers (details held in membership table), then they then define their availability (details held in availability table). Now, they may book appointments with other members and other members may book appointments with them, provided that the time they book is available according to the availability of the member they are trying to book with. (Sorry if thats a bit confusing)

    Anywho, my question is, am I missing anything that is necessary? or is there anything redundant in there that is not needed?

    Thanks for any advice or pointers, I'm kind of new to databases!

  2. #2
    Join Date
    Apr 2008
    Location
    Orange County, CA
    Posts
    1
    For one pointer I see right off the bat is that you should not have identical named fields in your tables. You should preface them like the availability table field "DATE" could be named AV_DATE, and the Appointment table field AP_DATE. This would be internal. If you have forms set up your lables can still read "DATE" but the field name would be AV_DATE or AP_DATE. This way if you run queries the database will error seeing DATE as ambiguous name not knowing which table to use.

Tags for this Thread

Posting Permissions

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