Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

this is what i have so far. i don\'t need the whole thing done for me but pointi

ID: 3805789 • Letter: T

Question

this is what i have so far. i don't need the whole thing done for me but pointing out what i did wrong so far and how to fix it would be of great help.

CREATE TABLE Person
(
Ssn       INTEGER,
Fname   VARCHAR(20),
Lname   VARCHAR(20),
Sex       VARCHAR(20),
Address   VARCHAR(20),
Bdate   VARCHAR(20),
Primary key (Ssn)
);

CREATE TABLE Student
(
Ssn           INTEGER,
Dname       VARCHAR(30),
Class       VARCHAR(30),
Foreign Key (Ssn) References Person(Ssn),
Foreign Key (Dname) References Department(Dname)
);
CREATE TABLE Major
(
Ssn       INTEGER,
Dname   VARCHAR(30),
Foreign Key (Ssn) references Student(Ssn),
Foreign Key (Dname) references Department(Dname)

);

CREATE TABLE GradStudent
(
);

CREATE TABLE Degree
(
Year       DATE,
Degree       VARCHAR(30),
College       VARCHAR(30)
);
CREATE TABLE Faculty
(
Ssn       INTEGER,
Dname   VARCHAR(30),
Rank   VARCHAR(20),
Foffice   VARCHAR(20),
Fphone   VARCHAR(20),
Salary   VARCHAR(20),
Foreign Key (Ssn) References Person(Ssn),
Foreign Key (Dname) References Department(Dname)
);

CREATE TABLE Department
(
Dname       VARCHAR(30),
Dphone       INTEGER,
Office       VARCHAR(30),
Primary Key (Dname)
);

CREATE TABLE Grant
(
St_date       DATE,
Title       VARCHAR(30),
Num           INTEGER,
Agency       VARCHAR(30)
);

CREATE TABLE Support
(
Start       DATE,
End           DATE,
Time       INTEGER
);

CREATE TABLE Section
(
SecNum   INTEGER,
Year   INTEGER,
Qtr       VARCHAR(20),
Primary Key (SecNum)
);

CREATE TABLE Course
(
Cname   VARCHAR(30),
Cnum   INTEGER,
Cdesc   VARCHAR(30)
);

Address Nairne) PERSON Cuss Police STUOENT Degrees GRAD STUDENT COMMITTE MINOR 2KN Star MAJOR SUPPO End BELON REGISTERED M NSTRUCTORRESEARCHE CHARS TEACH CURRENT SECTION Year Corrent, Risar DEPARTMENT CS Dphane CD COLLEGE COURSE Figure 8.9 Coffie An EER conceptual schems Chisme for a UNNERSITY database.

Explanation / Answer

The above relational mapping is almost correct but needs a minor corrections or additions apart from that you are almost there.

First make sure if there is any many to one or one to many relationships. We must add the primary key attribute in any one those participating attributes no need to create a new table.