I have two tables, course and prereg.
The attributes are like that,
course(course_id, title, dept_name, credits)
course_id attribute, of course, is the primary key.
course_id, pre_id attribute, of prereg, is the primary key.
On the other hand,
The attribute course_id in prereg is a foreign key from prereg referencing course.
I would like to know how could it be possible? At the same time, how can course_id become both primary key and foreign key?
The table is taken from the University schema of Database System Concept.