0% found this document useful (0 votes)
16 views

SQL Script

Uploaded by

FARINA KHAN
Copyright
© © All Rights Reserved
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views

SQL Script

Uploaded by

FARINA KHAN
Copyright
© © All Rights Reserved
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

create table employees ( employee_id number(6) primary key,first_name

varchar2(20),last_name varchar2(25) not null,email varchar2(25) not null


,phone_number varchar2(20),hire_date date not null ,job_id varchar2(10) not
null,salary number(8,2), department_id number(4), manager_id
number(6),commission_pct number(2,2));
prompt
insert into employees values(100, ' Steven', 'king', 'SKING', '515.123.4567' ,
'17-JUN-87' , 'AD_PRES', 24000,90, null ,null );
insert into employees values(101, 'Neena', 'Kochhar', 'NKOCHHAR',
'515.123.4568' ,'21-SEP-89' , 'AD_VP', 17000,90,100,null);
insert into employees values(102, 'Lex','De Haan', 'LDEHAAN', '515.123.4569' ,'13-
JAN-93' , 'AD_VP',17000,90 ,100,null);
insert into employees values(103, 'Alexander','Hunold', 'AHUNOLD',
'590.423.4567' ,'03-JAN-90' , 'IT_PROG',9000, 60, 102,null );
insert into employees values(104, 'Bruce','Ernst', 'BERNST', '590.423.4568' ,'21-
MAY-91' , 'IT_PROG',6000,60 ,103,null);
insert into employees values(107, 'Diana','Lorentz', 'DLORENTZ',
'590.423.5567' ,'07-FEB-99' , 'IT_PROG',42000, 60,103,null );
insert into employees values(124, 'Kevin','Mourgos', 'KMOURGOS',
'650.123.5234' ,'16-NOV-99' , 'ST_MAN',5800,50 , 100,null );
insert into employees values(141, 'Trenna','Rajs', 'TRAJS', '650.123.8009' ,'17-
OCT-95' , 'ST_CLERK',3500,50, 124, null);
insert into employees values(142, 'Curtis','Davies', 'CDAVIES',
'650.121.2994' ,'29-JAN-97' , 'ST_CLERK',3100,50 , 124,null );
insert into employees values(143, 'Randall','Matos', 'RMATOS', '650.121.2874' ,'15-
MAR-98' , 'ST_CLERK',2600,50 , 124, null);
insert into employees values(144, 'Peter','Vargas', 'PVARGAS', '650.123.8009' ,'09-
JUL-98' , 'ST_CLERK',2500,50, 124 ,null );
insert into employees values(149, 'Eleni','Zlotkey', 'PVARGAS',
'650.123.8009' ,'09-JUL-98' , 'SA_MAN',10500,80, 100, .2 );
insert into employees values(174, 'Ellen','Abel', 'PVARGAS', '650.123.8009' ,'09-
JUL-98' , 'SA_REP',11000,80, 149, .3 );
insert into employees values(176, 'Jonathon','Taylor', 'PVARGAS',
'650.123.8009' ,'09-JUL-98' , 'SA_REP',8600,80 , 149, .2 );
insert into employees values(178, 'Kimberely','Grant', 'RGRANI',
'011.44.1044.425200' ,'04-MAY-99' , 'SA_REP',7040,80 , 149, .15 );
insert into employees values(200, 'Jennifer','Whalen', 'JWHALEN',
'515.123.4444' ,'17-SEP-87' , 'AD_ASST',4400,10,101,null );
insert into employees values(201, 'Michalen','Hartstein', 'MHARTSTE',
'515.123.5555' ,'17-FEB-96' , 'MK_MAN',13000,20,100,null );
insert into employees values(202, 'Pat','Fay', 'PFAY', '603.123.6666' ,'17-AUG-
97' , 'MK_REP',6000,20,201,null );
insert into employees values(205, 'Shelley' , 'Higgins', 'SHIGGINS', '515.123.8080'
,'07-JUN-94' , 'AC_MGR' ,12000 ,110 ,101 , null);
insert into employees values(206, 'William' , 'Gietz', 'WGIETZ' ,
'515.123.8181' ,'07-JUL-94' , 'AC_ACCOUNT', 8300 , 110 , 205 , null );

create table DEPARTMENTS ( department_id number(4) primary key, department_name


varchar2(20),manager_id number(4), location_id number(10));
insert into departments values(20, 'Marketing' , 201, 1800);
insert into departments values(10, 'Administration' , 200, 1700);
insert into departments values(50, 'Shipping' , 124 ,1500);
insert into departments values(60, 'IT' , 103, 1400);
insert into departments values(80, 'Sales' ,149 ,2500);
insert into departments values(90, 'Executive' ,100,1700);
insert into departments values(110, 'Accounting' , 205,1700);
insert into departments values(190, 'Contracting' ,null ,1700);

create table JOB_GRADES(gra varchar(4) primary key, lowest_sal


number(9),highest_sal number(9));
insert into job_grades values('A' , 1000,2999);
insert into job_grades values('B' , 3000,5999);
insert into job_grades values('C' , 6000,9999);
insert into job_grades values('D' , 10000,14999);
insert into job_grades values('E' , 15000,24999);
insert into job_grades values('F' , 25000,40000);

create table locations ( location_id number(9) primary key, city varchar2(20));


insert into locations values(1400 , 'Southlake');
insert into locations values(1500 , 'South San Francisco');
insert into locations values(1700 , 'Seattle');
insert into locations values(1800 , 'Toronto');
insert into locations values(2500 , 'Oxford');

commit;

You might also like