Engineering Project Management Database David H. Williams CS 610

Preview:

Citation preview

Engineering ProjectEngineering ProjectManagement DatabaseManagement Database

David H. WilliamsDavid H. WilliamsCS 610CS 610

Departmental NeedsDepartmental Needs

Employee InformationEmployee InformationContractor InformationContractor InformationAccount Balance TrackingAccount Balance TrackingProject Information & TrackingProject Information & Trackinget alet al

CREATE TABLE employee(emp# CHAR(5) PRIMARY KEY,lname VARCHAR(20) NOT NULL,fname VARCHAR(30),mi CHAR(1),title VARCHAR(20),hire_date DATETIME NOT NULL

);

Employee TableEmployee Table

Account TableAccount TableCREATE TABLE account(

acct# CHAR(8) PRIMARY KEY,amount MONEY NOT NULL,update_stamp DATETIME,

);

Project TableProject TableCREATE TABLE project(

proj# CHAR(6) PRIMARY KEY,proj_name VARCHAR(50),proj_mang# CHAR(5) REFERENCES employee(emp#) ,planner# CHAR(5) REFERENCES employee(emp#) ,safety_eng# CHAR(5) REFERENCES employee(emp#) ,acct# CHAR(8) REFERENCES account(acct#),est_start DATETIME,est_end DATETIME,act_start DATETIME,act_end DATETIME,proj_descript VARCHAR(255));

Contractor TableContractor TableCREATE TABLE contractor(

cont_code CHAR(5) PRIMARY KEY,co_name VARCHAR(20) NOT NULL,address VARCHAR(100),city VARCHAR(30),state CHAR(2),zip CHAR(5),phone VARCHAR(12),contact_lname VARCHAR(20),contact_fname VARCHAR(30),minor_own char(1) CHECK(minor_own IN('y','n')),

);

Project – Contractor TableProject – Contractor TableCREATE TABLE pc_table( proj# CHAR(6) REFERENCES project(proj#) , cont_code CHAR(5) REFERENCES contractor(cont_code) , emps_on_proj INT, PRIMARY KEY (proj#,cont_code) );

Employee Table Account Table

Contractor Table

Project Table

PC Table

Reference FlowReference Flow

Microsoft Visual Studio .NETMicrosoft Visual Studio .NET

SQL Query AnalyzerSQL Query Analyzer

SQL Server Desktop EngineSQL Server Desktop Engine

Connecting to the Desktop ServerConnecting to the Desktop Server

Recommended