Access over 20 million homework & study documents

Structured Query Language (SQL)

Content type
User Generated
Type
Study Guide
Rating
Showing Page:
1/22
Running Head: LAB 4: STRUCTURE QUERY LANGUAGE (SQL) 1
Lab 4: Structured Query Language (SQL)
Your name
Your Instructor’s name
Course #
Your Institution’s name
Date:

Sign up to view the full document!

lock_open Sign Up
Showing Page:
2/22
LAB 4: STRUCTURE QUERY LANGUAGE (SQL)
Question 1: Create the tables and relationships from the database design discussed in Lab
2
CREATE TABLE IF NOT EXISTS `course` (
`courseId` int(11) NOT NULL AUTO_INCREMENT,
`name` varchar(40) NOT NULL,
`department` varchar(40) NOT NULL,
PRIMARY KEY (`courseId`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ;

Sign up to view the full document!

lock_open Sign Up
Showing Page:
3/22

Sign up to view the full document!

lock_open Sign Up
End of Preview - Want to read all 22 pages?
Access Now
Unformatted Attachment Preview
 Lab 4: Structured Query Language (SQL) Your name Your Instructor’s name Course # Your Institution’s name Date: Question 1: Create the tables and relationships from the database design discussed in Lab 2 CREATE TABLE IF NOT EXISTS `course` ( `courseId` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(40) NOT NULL, `department` varchar(40) NOT NULL, PRIMARY KEY (`courseId`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ; CREATE TABLE IF NOT EXISTS `course` ( `courseId` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(40) NOT NULL, `department` varchar(40) NOT NULL, PRIMARY KEY (`courseId`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ; CREATE TABLE IF NOT EXISTS `email` ( `emailId` varchar(100) NOT NULL, `type` varchar(40) NOT NULL, `personId` int(11) NOT NULL, PRIMARY KEY (`emailId`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1; CREATE TABLE IF NOT EXISTS `instructor` ( `instructorId` int(11) NOT NULL AUTO_INCREMENT, `firstName` varchar(40) NOT NULL, `lastName` varchar(50) NOT NULL, `address` varchar(200) NOT NULL, `gender` varchar(1) NOT NULL, `birthDate` date NOT NULL, PRIMARY KEY (`instructorId`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ; CREATE TABLE IF NOT EXISTS `instructor_courses` ( `instructorId` int(11) NOT NULL, `courseId` int(11) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; CREATE TABLE IF NOT EXISTS `phone` ( `phoneNumber` varchar(100) NOT NULL, `type` varchar(40) ...
Purchase document to see full attachment
User generated content is uploaded by users for the purposes of learning and should be used following Studypool's honor code & terms of service.

Anonymous
Nice! Really impressed with the quality.

Studypool
4.7
Trustpilot
4.5
Sitejabber
4.4