Question

This is an entire assignment that I need to be built into an ERD format, please...

media%2Fe06%2Fe06e88ab-b9d1-418a-8e5e-c6

media%2Fc17%2Fc172ed27-3c2e-4e8f-b72b-c6

media%2Fd82%2Fd821a7b1-1460-43df-ae2a-e8

This is an entire assignment that I need to be built into an ERD format, please assist me, thank you in advance.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

ERD nothing but Entity Relationship Diagram Format Used to demonstrate the Relationship and co-relations between different attributes of the created db tables.

As per the given problem Statement , Below Tables to be created in SQL database Repository

First will create a database with name 'testDB' using SQL Command 'CREATE DATABASE testDB;'

execute the command in SQL Command Window this will create New SQL Database 'testDB'

After creating Database create the needed tables

Table 1: Student to hold attributes like 'the matriculation number, first name, last name, home address, data of birth, sex, category, nationality, smoker, special needs, additional comments, current Status, department'

with the above listed attributes will create new table Student under newly created SQL Databse 'testDB'

CREATE TABLE Student

(matriculation number INTEGER NOT NULL,first name VARCHAR(3000), last name VARCHAR(3000), home address VARCHAR(4000), data of birth VARCHAR(100), sex VARCHAR(15), category VARCHAR(40), nationality VARCHAR(100), smoker BIT DEFAULT 0, special needs VARCHAR(1000), additional comments VARCHAR(4000), current Status VARCHAR(500), department VARCHAR(100)',PRIMARY KEY(matriculation number));

Ran the above command to create Table Student

Every Student is assigned to a Staff Who acts as an advisor, Advisor Table contains the below attributes and create table 'Advisor' with below SQL Command

CREATE TABLE Advisor

(name VARCHAR(1000), position VARCHAR(2000),department name VARCHAR(1000), phone INTEGER, room number INTEGER);

Ran the above command to create Table Advisor.

Advisor can be a Staff to one or more Students and all Students activities are monitered (or) tracked by the Advisor

Students who are studing in college can rent a room @ 'hall_of_residence' or @ 'student_flats' at one time they can be part of one residence only (i.e) either part of 'hall_of_residence' or either part of 'student_flats'

Illustrated the SQL Comments to create tables 'hall_of_residence' and 'student_flats'

CREATE TABLE hall_of_residence

(place number INTEGER NOT NULL,name VARCHAR(3000),Address VARCHAR(4000),monthly rent INTEGER, PRIMARY KEY (place number));

Ran the above command to create Table hall_of_residence.

CREATE TABLE student_flats

(flat number INTEGER NOT NULL, flat address VARCHAR(3000), bedroom INTEGER,monthly rent INTEGER, PRIMARY KEY (flat number ));

Ran the above command to create Table student_flats.

Leases Agreements are made between the Students with needed information (like room number, how many years thery are going to stay etc.,)

Illustrated below how to create table leases

CREATE TABLE leases

(lease number INTEGER NOT NULL, lease duration INTEGER, student name VARCHAR(3000), matriculation number INTEGER NOT NULL, place number INTEGER NOT NULL, flat number INTEGER NOT NULL, Address VARCHAR(4000), flat address VARCHAR(3000), lease start date VARCHAR (500), lease end date VARCHAR(500), PRIMARY KEY (lease number), FOREIGN KEY (matriculation number) REFERENCES Student(matriculation number), FOREIGN KEY (place number) REFERENCES hall_of_residence(place number), FOREIGN KEY (flat number) REFERENCES student_flats(flat number), FOREIGN KEY (Address) REFERENCES hall_of_residence(Address), FOREIGN KEY (flat address) REFERENCES student_flats(flat address));

Use the above SQL Command to create table leases

Foreign Key references are used since all sttributes mentioned in leases table is already created as part of eariler created SQL tables so no need to have a new reference, instead use Foreign Key References as show above.

As mentioned above create remaining tables

Create Tables ' invoice, accomaondation staff, student flat inspections and next-of-kin ' using below SQL commands

CREATE TABLE invoice

(invoice number INTEGER NOT NULL, lease number INTEGER NOT NULL, payment due INTEGER, student name VARCHAR(3000), matriculation number INTEGER NOT NULL, place number INTEGER NOT NULL, flat number INTEGER NOT NULL, Address VARCHAR(4000), flat address VARCHAR(3000), method of pay VARCHAR(500), FOREIGN KEY (lease number) REFERENCES leases(lease number), FOREIGN KEY (matriculation number) REFERENCES Student(matriculation number), FOREIGN KEY (place number) REFERENCES hall_of_residence(place number), FOREIGN KEY (flat number) REFERENCES student_flats(flat number), FOREIGN KEY (Address) REFERENCES hall_of_residence(Address), FOREIGN KEY (flat address) REFERENCES student_flats(flat address));

CREATE TABLE Accomadation_Staff

(name VARCHAR(3000), Address VARCHAR(4000), date of birth VARCHAR(200), sex VARCHAR(20), position VARCHAR(1000), location VARCHAR(1000));

CREATE TABLE Student_Flat_Inspections

(inspection_data VARCHAR(200), inspection_staff_name VARCHAR(3000), additional_comments VARCHAR (4000));

CREATE TABLE Next_of_Kin

(name VARCHAR(2000), relationship VARCHAR(1000), address VARCHAR(2000), phone INTEGER);

Use the above SQL Comments to create tables 'invoice, accommodation staff, student flat inspections and next-of-kin'

After creating all these table , then will create ERD to illustrate the co-relation between all created tables

Add a comment
Know the answer?
Add Answer to:
This is an entire assignment that I need to be built into an ERD format, please...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Please, help with this question. I need 1 page paper and reference(s) with APA format thank...

    Please, help with this question. I need 1 page paper and reference(s) with APA format thank you. Please, "No plagiarism," do not copy things and paste them. Thank you in advance. DISCUSSION BOARD ASSIGNMENT: Discuss why "use of technologies to assist in effective communication in a variety of healthcare settings" is listed as an expected nurse competency by QSEN and other nursing organizations.

  • ​#6 I need this done very soon. Please just provide the answers in the format that...

    ​#6 I need this done very soon. Please just provide the answers in the format that it has asked for. Thank you very much in advance.

  • I need help with this assignment, please help! Thank you.

    I need help with this assignment, please help! Thank you.

  • I need help with this please. I am so confused with this assignment. Thank you in...

    I need help with this please. I am so confused with this assignment. Thank you in advance. Match the characteristics to the radiation interactions: Types of Ionizing Radiation: a.Coherent Scattering b.PhotoElectric Absorption c.Compton Interaction d.Brem's Radiation e.Pair Production f. PhotoDistegration Characteristics: 1. Is associated with characteristic Radiation 2. Results in neutron Emission 3. Results in liberated electrons and altered energy photons 4. Occurs with very low photon energies 5. Inelastic event of electron with the Nucleus

  • please so important (I need no plagiarism, please) NO plagiarism PLEASE I GIVE YOU ALL THE...

    please so important (I need no plagiarism, please) NO plagiarism PLEASE I GIVE YOU ALL THE INSTRUCTION TO IT Hi I need help with my homework please I give you all the instruction on the assignment I need help with it please it is very important please be clear and give me a good answer and very important please so important (I need no plagiarism, please) and also copy and paste it better and clear to read. Must be 300...

  • Hi I need help with my homework please I give you all the instruction on the...

    Hi I need help with my homework please I give you all the instruction on the assignment I need help with it please it is very important please be clear and give me a good answer and very important please so important (I need no plagiarism, please) and also copy and paste it better and clear to read. Must be 300 words assignment guidelines: Must be 300 words Must be AMA format Must be third person and please give me...

  • Hi, PLEASE I need the code in C programming, (USING THE SAME INPUT AND OUTPUT FORMAT...

    Hi, PLEASE I need the code in C programming, (USING THE SAME INPUT AND OUTPUT FORMAT DESCRIBED BELOW). Title: Game of Life Description In this assignment, you will code a simulation called "Game of Life". It is a very famous 'game' and the formed the basis of an entire field of simulation models called "cellular automata". Before continuing reading this assignment, I suggest you read a bit more about Game of Life at: https://en.wikipedia.org/wiki/Conway's_Game_of_Life or http://www.math.com/students/wonders/life/life.html (the latter also has...

  • 2.a Please inte rpret the ERD as below. You need to interpret the entities and the...

    2.a Please inte rpret the ERD as below. You need to interpret the entities and the meaning of the relationship, including the participation (5 points) 2.b Mapping the ERD into a relational schema (table structures) (5 points). 2.c Show several records in each relation (table) and mark those values that indicate the participation (5 points). DegreeName

  • Can you please, please help me with this assignment? I am extremely desperate and I have...

    Can you please, please help me with this assignment? I am extremely desperate and I have no idea what to do or say. Is there any way possible you could please, please, please cite a source in APA format with your answer? I would be extremely grateful to you and I appreciate your time and effort. 1) What is the meaning of sensitivity analysis, scenario analysis, and simulation analysis? 2) For example: If I want to buy a house and...

  • Can someone give me a sample of SOAP Format Analysis of Dietary Intake (SOAP stands for...

    Can someone give me a sample of SOAP Format Analysis of Dietary Intake (SOAP stands for Subjective, Objective, Assessment and Plan). I need it for my assignment in Nutrition class. Thank you

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT