Results 1 to 9 of 9
  1. #1
    dharmacloud is offline Novice
    Windows Vista Access 2007
    Join Date
    Aug 2011
    Posts
    21

    Smile Need with database

    I'm trying to complete this project on student records database. However, I'm a bit stuck on a few problems. Anyone willing to look at my database and offer some help?



    many thanks in advance!

  2. #2
    Robeen is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Mar 2011
    Location
    Tulsa, Oklahoma.
    Posts
    1,593
    Do you have some specific questions that you can post?

    I'll certainly try & help.

  3. #3
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    I do believe that is precisely what this forum is designed for. You post a question and we Google it on your behalf (KIDDING!). What are you stuck on?

  4. #4
    dharmacloud is offline Novice
    Windows Vista Access 2007
    Join Date
    Aug 2011
    Posts
    21
    I have an SQL that is currently a UNION JOIN but need to change it to LEFT JOIN. How to go about doing this? Here's the SQL:


    Code:
    SELECT Register.Reg_ID, Register.CourseOfferingsID, Register.StudentProgramID,
                    StudentProgram.StudentID, StudentProgram.ProgramID, Register.RegisterDate, Register.RegisterUnit,
                    Register.RegisterGrade,
                    Register.RegisterGradingBasis, Register.RegisterType, Register.RegisterNote, 0 AS Transferred
    FROM Register, StudentProgram
    WHERE Register.StudentProgramID = StudentProgram.StudentProgramID and Register.TxStudentProgramID is Null
    
    UNION SELECT Register.Reg_ID, Register.CourseOfferingsID, Register.TxStudentProgramID as StudentProgramID, 
                    StudentProgram.StudentID, StudentProgram.ProgramID, Register.RegisterDate, Register.RegisterUnit,
                    Register.RegisterGrade,
                    Register.RegisterGradingBasis, Register.RegisterType, Register.RegisterNote, 1 AS Transferred
    FROM Register, StudentProgram
    WHERE Register.TxStudentProgramID = StudentProgram.StudentProgramID;

  5. #5
    Robeen is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Mar 2011
    Location
    Tulsa, Oklahoma.
    Posts
    1,593
    One really quick way would be for you to split the Union query into two separate queries.

    1. Create a new query.
    2. Don't select a table. Close the 'Show Table' dialog box & SQL View.
    3. In the SQL window - paste the first part of the Union query.
    4. Save & name the query.

    Then create another query in the same way for the second part of the Union query.

    Create a 3rd query in Query Design mode and select the two above queries that you created.

    In the graphical interface - create the Left Join.

    I'm not sure if this is what you really WANT to do. If it is not, give us some more details.
    Last edited by Robeen; 08-22-2011 at 11:17 AM. Reason: Needed to clarify what original poster wants to do.

  6. #6
    dharmacloud is offline Novice
    Windows Vista Access 2007
    Join Date
    Aug 2011
    Posts
    21

    more complicated problem

    For my student records database, I need help to figure out how I should go about creating tables and queries for course registration. The complicated part of the course registration is keeping track of the students and their program of study and the courses that they take during that program. For example, a student in a bachelor's program for 4 years takes X number of courses. After she graduates, she then continues to take courses but is no longer under the bachelor program. Her status is "non-degree" or "special". The courses she takes under the special status would need to be identified as such. She then enters the Master's program and all her courses taken as MA status need to be tracked.

    The reason I need to make sure that the courses is tracked by the program is because students are allowed to transfer the courses which they take under "special" status into the degree program (bachelor or masters). That's the other complicated part. How should I go about creating a table which allows the user to select the courses that they want to transfer into the degree programs. Not all courses are transferable. The limit is 12 units of coursework can be transferred. So, I need to be able to choose which courses to transfer into the degree program.

    Currently, I have the following tables:
    1. Courses [CourseID, coursecode, courseName, Course Unit, course type]
    2. Courses Offered [CourseOfferedID, CourseID, CourseName, Year, Term, instructor, location]
    3. Student [studentID, name, address, gender, DOB, SSN, Date enrolled, ethnicity, student number]
    4. Program [ProgramID, ProgramName, ProgramAbbreviation, Level]
    5. Student Program [studentProgramID, studentID, ProgramID, date start, date end]
    6. Register [RegisterID, StudentProgramID, CourseOfferedID, register date, register unit, register grade, register grading basis.]

    Queries:
    1. CourseRegistration [registerID, studentID, studentprogramID, coursename, courseID, register unit, register date, register grade, register grading basis, course term, course year]
    2. student program [studentprogramID, studentID, ProgramID, date start, date end] date end is null to show only the current program that the student is in right now.

    Please give me suggestions on how to go about this process.

  7. #7
    Robeen is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Mar 2011
    Location
    Tulsa, Oklahoma.
    Posts
    1,593
    Where are you recording the Student's Status?

  8. #8
    dharmacloud is offline Novice
    Windows Vista Access 2007
    Join Date
    Aug 2011
    Posts
    21
    the student status will be in the student program table

  9. #9
    dharmacloud is offline Novice
    Windows Vista Access 2007
    Join Date
    Aug 2011
    Posts
    21
    The student program table will have the start date and end date of the program(s) that they have been in or the current program that they are in. For example:
    John Doe start date end date
    bachelor 6/1/1997 to 6/5/2001
    Special 9/1/2001 to 6/5/2002
    Master 6/1/2002 to

    Not sure if that's the best way to do it but I was thinking that I could then make other queries based on this. The current program that the student is in does not have an end date. So when I query for the current program, then I just put Is null under the end date criteria.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Database Design for Specification Database
    By khwaja in forum Database Design
    Replies: 2
    Last Post: 11-24-2011, 03:58 AM
  2. Replies: 20
    Last Post: 08-08-2011, 01:34 PM
  3. Replies: 3
    Last Post: 05-15-2011, 10:52 PM
  4. Replies: 1
    Last Post: 11-03-2010, 10:41 AM
  5. Replies: 4
    Last Post: 08-12-2010, 08:38 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums