Question: --1a. Write a SQL statement that create a database and then drop the database. --1b. Write a SQL statement that create a table Employee, columns

--1a. Write a SQL statement that create a database and then drop the database.

--1b. Write a SQL statement that create a table Employee, columns should be EmployeeID which is in integer type, Last Name and First Name in varchar type, age in integer type. Make sure EmployeeID is the key and every employee is older than 21 year-old.

--1c. Write a SQL statement that insert the following values into 1b.table, explain which row cannot be inserted into the table and why. (001, Jason Unwin, 20) (001, Jason Unwin, 22) (001, James Unwin, 33) (002, John Unwin, 20) (002, Jason Unwin, 26)

--2. Write a SQL statement that explain the differences between DELETE, DROP and TRUNCATE

--3. Write a SQL statement that define a procedure which contains 1b and 1c, and run it.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!