From: "Pushpinder Singh" <[EMAIL PROTECTED]> > I am designing a PHP and MySQL based online Testing Application. > The application will consist of about 120 lessons and each lesson will > have a quiz at the end of the lesson. There will also be some core > lessons that all test takers will have to pass before going ahead. > There will be a good number of optional/elective courses. > > The main page that I am trying to design a page which will tell a user, > what lessons he/she has passed, what lessons he /she is eligible to > take and the lessons he /she cannot take at the moment. The lessons are > numbered sequentially like Lesson 101, 102, 103, 104, 105 , 106 > ....110. Out of them e.g. only Lesson 101 and 104 are CORE > requirements, the rest are just electives. However a person cannot do > Lesson 106 (which is an elective ) till he /she has passed Lesson 104.
What about just a parent-child relationship? Lessons 101 and 104 will have no parent and the others have parents that are the prerequisites. So 106 has a parent of 104, meaning 104 must be completed first. Or just use a separate table that lists relationships in two columns: class_id and prereq_id. So 101 and 104 would have no entries and 106 would have one entry for 104. This method would be useful for classes that may have more than one prerequisite, also. ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php