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

: Create tables DDL queries. Add appropriate data to each table. : Create simple

ID: 3732415 • Letter: #

Question

: Create tables DDL queries. Add appropriate data to each table. : Create simple/complex views for the end-users. : Design data retrieval queries using various joins, functions, set operators and nested queries. : Utilize various database objects like synonym, view, sequence and index. : Implement user access control for different object. : Use PL/SQL blocks(procedure/ function/package/trigger) for data manipulation.
Locations location no (PK) location name street address postal code city state_province department dept no (PK) dept name location no (FK) employees emp_no (PK) first name last name birth date gender dep no (FK) title no (FK) EmpProject emp proj.no (PK) proj no (FK) emp no (FK) start_date hours on project status titles title_no(PK) title Project proj.no (PK) proj name

Explanation / Answer

Solution:

The create table queries are given below, please repost your other questions.

CREATE TABLE Locations(
    location_no int NOT NULL,
location_name;

street_address;

postal_code;

city;

state_province;
    PRIMARY KEY (location_no)
);

CREATE TABLE Department(
    dept_no int NOT NULL,
    dept_name int NOT NULL,
    location_no int,
    PRIMARY KEY (dept_no),
    CONSTRAINT FK_location_no FOREIGN KEY (location_no)
    REFERENCES Student(location_no)
);

CREATE TABLE employees(
    emp_no int NOT NULL,
first_name;

last_name;

birth_date;

gender;

dept_no;

location_no
    PRIMARY KEY (emp_no);

CONSTRAINT FK_location_no FOREIGN KEY (location_no)
    REFERENCES department(location_no)

CONSTRAINT FK_dept_no FOREIGN KEY (dept_no)
    REFERENCES Locations(dept_no)
);

CREATE TABLE EmpProject(
    emp_proj_no int NOT NULL,
proj_no int NOT NULL,
emp_no int,

start_date,

hours_on_project,

status,
    PRIMARY KEY (emp_proj_no),
    CONSTRAINT FK_proj_no_no FOREIGN KEY (proj_no)
    REFERENCES Student(proj_no)

    CONSTRAINT FK_emp_no FOREIGN KEY (emp_no)
    REFERENCES Student(emp_no)
);

CREATE TABLE title(
title_no int NOT NULL,
title;

PRIMARY KEY (title_no)

);

CREATE TABLE Project(
proj_no int NOT NULL,
proj_name;

PRIMARY KEY (proj_no)

);

I hope this helps if you find any problem. Please comment below. Don't forget to give a thumbs up if you liked it. :)

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote