Hello! I am putting together an Entity Relationship Diagram for a DBMS class. If
ID: 3723808 • Letter: H
Question
Hello! I am putting together an Entity Relationship Diagram for a DBMS class. If I wanted to see how I should document a first_name and last_name instance on two separate tables. Would that be a foreign key? I want to make it when I update the opportunity record, the student record will also update. Can someone check and see if I made any other mistakes?
Thanks!
EnrollmentAdvisor PK EnrollmentAdvisorlD EnrollmentAdvisorLastName EnrollmentAdvisorFirstName AcademicAdvisor PK AcademicAdvisorID AcademicAdvisorLastName AcademicAdvisorFirstName Student Record PK StudentID FK AcademicAdvisorID FK Student EnrollmentID FK Mailing Address Phone Number School_Email_Address Student Status Opportunity Recoro PK OpportunitylD FK EnrollmentAdvisorlD FK StudentiD FK SourceCodelD FK MailingAddressID First Name Last_Name Home Phone Work_Phone Mobile_Phone Email_Address EmployerName Last_Called Date Last Contacted Date Last Emailed _Date Opportunity_Stage Opportunity_Status Marketing SourceCode PK SourceCode|D Vendor Name Lead Cost Student Enrollment PK Student_EnrollmentID FK StudentID FK ProgramID ClassID AdmitDate GraduationDate H Program PK ProgramlD FK CourselD ProgramDescription Mailing Address PK Mailing_AddresslD HH Address 1 Address 2 City State Zipcode Time Zone Country Courses PK CourselD Course Section_Number FK ProfessorID Start_Date End Date Course Cost Professor PK ProfessorID Professor FirstName Professor LastNameExplanation / Answer
Answer)
For the Student Record, I think StudentID is the primary key. Student Record should also contain the First_Name and Last_Name of the Student.
For the Opportunity Record, First_Name and Last_Name entry is not required as StudentID is a foreign key which references Student table's StudentID.
Thus when you change some details related to Student when it will automatically get updated in the Opportunity Record. Thus here the foreign key approach is necessary in the above way.
I find rest all E-R are ok and correct. In any table, the details of the details of the foreign key should not be there. The foreign key id should be there. Details should be there where the foreign key id is the primary key of the table. The above diagram is correct except the modification to be made as mentioned above.
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.