Richcoleuk
November 24th, 2003, 04:00 PM
Hello i am in the process of designing a database. I have my conceptual model and following the rules of normalisation have converted this into a relational schema. One of my entities from the model is called student. I have used a disjoint mandatory heirarchy and this creates two subclasses called undergraduate and postgraduate under the superclass student. The student entities has the attributes studentno, firstname, lastname and address. Student no being the primary key. The subclass postgraduate only has supervisor name. Undergraduate has department, and year tutor.
Okay when i use the rules to turn this into a table in my relational schema should i end up with two tables undergraduate and post graduate. The schema should look like:
undergraduate(studentno, firstname, lastname, address, department, yeartutor)
and
postgraduate(studentno, firstname, lastname, address, supervisor)
Is this right? Have i converted the model correctly into a relational schema?
If so how do i create these two tables with SQL as they both have the same primary keys? any help much obliged thankyou
Okay when i use the rules to turn this into a table in my relational schema should i end up with two tables undergraduate and post graduate. The schema should look like:
undergraduate(studentno, firstname, lastname, address, department, yeartutor)
and
postgraduate(studentno, firstname, lastname, address, supervisor)
Is this right? Have i converted the model correctly into a relational schema?
If so how do i create these two tables with SQL as they both have the same primary keys? any help much obliged thankyou