"csengsto" <sengc (AT) web (DOT) de> wrote
Quote:
students are examined from profs about lectures.
I mean, an examination with one professor and one student about one lecture.
But a student may have several exams, and a prof may keep several
examinations. Ha! what is it like?
[stud]-M---<exam.>---1-[prof]
[lect]_1__/
or
[stud]-1---<exam.>---M-[prof]
[lect]_1_/
or
[stud]-1---<exam.>---1-[prof]
[lect]_1__/
isnīt the last one only "one" examination for one student?
maybe someone can read this ER scratch! Thanks, Chris |
Well, it isn't trivial when you are new to modeling. You are missing
all those other students, profs, exams and lectures from the model?
Your first diagram shows an examination of one (maybe zero) or more
students. The second one is one student being grilled, for whatever
reason, by maybe a full body of professors. The third diagram represents
the situation you described: "one professor and one student about one
lecture".
Entities are modeled as types.
ER diagrams contain (hopefully) true statements involving those
types and their relationships in a visual language.
An ER diagram does not care how many students etcetera actually exist,
it fits all cases with (0, 1, N) instances of each type.
If there are zero instances of entity "professor", then it can be
correctly inferred from the model that there can be no examinations.
Regards,
Theo Peterbroers