Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2009
    Posts
    8

    Unanswered: Student Database Help

    Good day,

    Ok i was assigned the task of making a student database for all the students in a class. The database through a switchboard should be able to add students delete students and perform queries to find an individual student and determine what subject he currently has and the instructor for that subject.

    What i've done so far

    Created the student table with the following fields: - Student ID, Student Name, Age, Sex, Grade, Parent/Guardian, Contact Number, Email

    schedule table (have one for each day of the school week) fields:- Period, Subject, Instructor, Start Time, End Time

    My question is can someone please indicate to me how to created the necessary queries to perform the objective of my database. What I can't seem to figure out is how i'm suppose to link these two tables

    I'm using access 07 btw

    Thanks in advance for any help given
    Last edited by netlab; 01-26-09 at 18:12.

  2. #2
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    how to created the necessary queries to perform the objective of my database.
    Since you haven't specified the objectives, it is impossible to answer that.

    What I can't seem to figure out is how i'm suppose to link these two tables
    You can't because there is no foreign key in your schedule table.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  3. #3
    Join Date
    Jan 2009
    Posts
    8
    thanks for the reply, actually the objective is a query to display the
    Student Name, Period, Subject, Grade, Instructor from entering the student name and period. I've kind of figured out how to perform the query but without proper relationship among the tables it don't display the correct info.

    Would it be possible for you to give me a sample on how i can link the tables i have no idea of an appropriate foreign key to use

    Thanks for your input i realise that my tables are incomplete

  4. #4
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    First, get rid of Age. Such a field is crazy... who is going to be tasked with keeping the age current for every student? Instead just store DOB and then age is just a calculation.

    As for linking, there is a significant design problem. Just adding a foreign key isn't going to work since a scheduled session (Period, Subject, Instructor, Start Time, End Time) needs to have many students associated with it and each student will need many sessions associated with them, so you need to study up on how to create a many to many relationship.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  5. #5
    Join Date
    May 2005
    Posts
    1,191
    Quote Originally Posted by netlab
    Would it be possible for you to give me a sample on how i can link the tables
    This wouldn't happen to be a homework problem would it? The reason I ask is that I see a post from a new member asking almost the exact same thing about once a month. What you've asked for is a classic homework problem.
    Me.Geek = True

Posting Permissions

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