STUDENT NAME:. 11 October 2016. SQL HW #3: DDL and DML

Added on - 21 Sep 2019

  • 4

    pages

  • 398

    words

  • 102

    views

  • 0

    downloads

Showing pages 1 to 2 of 4 pages
STUDENT NAME:11 October 2016SQL HW #3: DDL AND DML SQL0|P a g e
1.Create database My_BIS325;2.CREATE TABLE Employee (first_name varchar(50) NOT NULL,last_name varchar(75) ,middle_initial varchar(1) ,home_phone varchar(12) NOT NULL,social_security_number varchar(11) NOT NULL,home_address varchar(100) NOT NULL,home_state varchar(20) NOT NULL,home_city varchar(20) NOT NULL,Salary decimal(10,2) NOT NULL,Email varchar(100) NOT NULL,PRIMARY KEY (social_security_number));3.CREATE TABLE Projects(Project_ID int NOT NULL AUTO_INCREMENT,Project_name varchar(250) NOT NULL,PRIMARY KEY (Project_ID));4.INSERT INTO Projects(Project_name) VALUES ('Alpha');INSERT INTO Projects(Project_name) VALUES ('Beta');OUTPUT:5.INSERT INTO Employee(first_name, last_name, middle_initial, home_phone,social_security_number, home_address, home_state, home_city, salary, email)VALUES('Brian', 'Finnegan', 'Q', '215.670.9308', '123-45-6789', '1420 Pine St', 'PA', 'Philadelphia','17500', 'joeyjoejojojr_shabadoo@hotmail.com');SELECT * FROM Employee;1|P a g e
desklib-logo
You’re reading a preview
card-image

To View Complete Document

Become a Desklib Library Member.
Subscribe to our plans

Download This Document