Create a company database, Database Management System

Assignment Help:

Company Database:

a-)Here is the ER Model

1172_Create a Company Database 1.png

b-)Here is the Relational Model:

 

681_Create a Company Database 2.png

 
IMPORTANT NOTICE FOR SOLUTION TYPE:

***THIS ASSIGNMENT WILL BE SOLVED BY THE FOLLOWING THIS TYPE AND EXAMPLE!!!

SOLUTION TYPE:

SELECT   Distinct Lname, Fname

FROM       Employee, Department, Dependent

WHERE    SSN=mgrssn and ssn=essn;

SOLUTION TYPE:

SELECT   pnumber,dnum,lname,address,bdate

FROM       project,department,employee

WHERE    dnum=dnumber and mgrssn=ssn and plocation='Stafford';

EXAMPLE:

STEP# 1: CREATE TABLE dependent

( essn  char(9),

dependent_namevarchar(15),

sex            char,

bdate          date,


relationshipvarchar(8),

primary key (essn,dependent_name));

STEP #2:

INSERT INTO dependent VALUES ('333445555','Alice','F','05-APR-86','Daughter');

INSERT INTO dependent VALUES ('333445555','Theodore','M','25-OCT-83','Son');

INSERT INTO dependent VALUES ('333445555','Joy','F','03-MAY-58','Spouse');

INSERT INTO dependent VALUES ('987654321','Abner','M','28-FEB-42','Spouse');

INSERT INTO dependent VALUES ('123456789','Michael','M','01-JAN-78','Son');

INSERT INTO dependent VALUES ('123456789','Alice','F', '31-DEC-88','Daughter');

INSERT INTO dependent VALUES ('123456789','Elizabeth','F','05-MAY-67','Spouse');

STEP #3: ALTER TABLE dependent ADD CONSTRAINT dependent_essn_fk foreign key (essn)  references employee(ssn);


Related Discussions:- Create a company database

How is concurrency identified, How is concurrency identified? Concurren...

How is concurrency identified? Concurrency in objects can be identified by the way they alter their state. Current objects can change their state independently. Aggregation imp

Information infrasctructure., what factors might influence a company to out...

what factors might influence a company to outsource its IT infrascture.

What are aggregate functions, What are aggregate functions? And list the ag...

What are aggregate functions? And list the aggregate functions supported by SQL? Aggregate functions are functions that take a collection of values as input and return a one va

Benefits and drawbacks of sequential file organisation, Benefits of Sequent...

Benefits of Sequential File Organisation It is quick and efficient when dealing with huge volumes of data that require being processed periodically (batch system). Dra

What is system catalog or catalog relation, What is system catalog or catal...

What is system catalog or catalog relation? How is better known as? A RDBMS maintains a explanation of all the data that it contains, information about every relation and index

Business process model, Consider a research paper submission process. The p...

Consider a research paper submission process. The process starts when an author submits a draft research paper (the paper may have up to 3 authors) to the chair of the organizing c

What is relationship instance, What is relationship instance ? Relation...

What is relationship instance ? Relationship Instance - A relationship is a relation between two or more entities. An instance of relationship set is a set of relationships.

Explain the terms data warehousing and data mining, Question: i) Explai...

Question: i) Explain the terms data warehousing and data mining. ii) Discuss the importance of the following security principles that a digital firm should amongst others, n

Explain interfaces for parametric users, Explain Interfaces for parametric ...

Explain Interfaces for parametric Users? Interfaces for Parametric Users - Parametric users, such as bank tellers, frequent have a little set of operations in which they must p

Explain relational model and their use in dbms, Explain Relational model an...

Explain Relational model and their use in DBMS? Relational Model - The relational model was first introduced through E.F. Codd of the IBM Research in the year of 1970. The mode

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd