selecting tables, with variables
Posted 02 January 2004 - 02:41 AM
Posted 02 January 2004 - 09:56 AM
If there\'s some other reason for this design, I suspect you\'ve gotten off on the wrong track.
Posted 02 January 2004 - 04:31 PM
When designing a database you want to be looking to normalise the data to prevent redundancy (I\'m sure there is a nice example of this but I don\'t have the url handy maybe someone can help?)
It\'s difficult to help without a further understanding of the context.
Posted 02 January 2004 - 07:39 PM
The only time this isn\'t suitable is if each username can have many grades/teachers/etc attached to it.
As you stated, if the database is focused on recording data about students, including classes taken, grades given, teachers etc... then this should be reflected in a normalized database structure.
Here\'s a quick data model I did illustrating a full featured database model with a few assumptions made, that
-Records All classes by subject
-Records a semester (grade period in this model) where class was offered
-Indicates teacher who taught class for semester
-Records students in the class
-Records tests given to class
-Records grade for each student for each test given in class
This supports any number of teachers, students and classes in combination. It doesn\'t support a class having more than one teacher, but that could be easily added at the cost of a little more complexity.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users