Re: [SLUG] RFC: Gradebook Project Database

From: Pat Morris (p2002morris@yahoo.com)
Date: Tue Oct 15 2002 - 18:18:13 EDT


Are you thinking about defining a class period table, where for a class period there would be a unique period id, a period time and an associated class id? Then change the student table to refer to the period rather than the class, since the class id would be in the period table? This would work, but probably is normalized too much for the volume of data you will be looking at, where any schools classes by period is probably less than a million rows - you can do the same thing by just adding class time to the class table, with the understanding you will have multiple rows for multiple classes, but because this is such a low volume table the advantage of not having to refer to another table would probably more than make up for it - for example:
select c.class_name, c.class_period, s.student_name from tbl_class c, tbl_student_class s where c.class_id = s.class_id

vs

select c.class_name, c.class_period, s.student_name from tbl_class c,tbl_student_class s, tbl_class_period p where s.class_id = p.class_id AND c.class_id = c.class_id

-As you can see - the second statement is much more expensive in context of resourses -Pat

 Ronan Heffernan <ronan@iotcorp.com> wrote:

>
>>STUDENTS_CLASSES_TBL(_STUDENT_ID_, _CLASS_ID_, CLASS_PERIOD,GRADE_AVG)
>>
>
>
> The classes_tbl would really need the class_period field, not this one.
> This is just a many-to-many table to link students to classes. And
> grade_avg? Really needed?

Yes and no. There should be another layer which defines a particular
class, occurring at a certain period (and semester and schoolyear, so
you don't have to clear your entire database each semester). The
CLASSES_TBL is a good thing, acting as a course catalog. The name and
description of the class may not change for many years (the same "AP
English" class is offered every year). But you're right, there should
be another layer above STUDENTS_CLASSES_TBL.

--ronan

---------------------------------
Do you Yahoo!?
Faith Hill - Exclusive Performances, Videos, & more
faith.yahoo.com



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 16:13:36 EDT