Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!

Suggestions on table layout please

Discussion in 'Information Technology' started by Charles, Jul 28, 2006.

  1. Charles

    Expand Collapse


    I am wanting to create a simple database that will record my daily post
    assignments. So basically I need the following information:

    Date, Start Time, End Time, Post Assignment, Shift Supervisor Name,
    Supervisor Name, Co-Worker(s) name.

    I also need to be able to keep track of days that I use leave instead
    of work, and there will be times when part of the day will be worked,
    and part used leave. I can have multiple co-workers, my post
    assignment can change during the day, my supervisor can change during
    the day, and there will be times where I have no supervisor, but
    instead I am the supervisor. Below is the layout I have come up with,
    but I believe it is limited:

    Post(PostID, PostName, PostLocation)
    **Post Name would be like A dorm, Post location would be either Work
    Camp or Main Unit

    Employee(EmployeeID, LastName, FirstName, Rank)

    LeaveType(LeaveTypeID, LeaveType)

    WorkEvent(WorkEventID, Date, StartTime, EndTime, PostID,
    ShiftSupervisor, Supervisor, CoWorker, WorkedAsSupervisor, Notes)
    **PostID is direct link to Post Table. ShiftSupervisor, Supervisor,
    and Coworker all lookups of Employee Table. WorkedAsSupervisor would
    be a yes/no. Now this is where the weakness in this layout is... At
    times I will have one supervisor, and one coworker. Other times I will
    have one supervisor, and no coworkers, then sometimes I will be a
    supervisor with one or two coworkers... not sure how to resolve this

    LeaveEvent(LeaveEventID, Date, StartTime, EndTime, LeaveTypeID,
    Scheduled, Notes)
    **LeaveTypeID lookup of Leave table, Scheduled is a yes/no

    Any help in resolving this weakness is much appreciated... keep in mind
    with your replies that I am a self taught rookie at this so...

  2. Loading...

Share This Page