Initial Commit
BIN
Assignments/As1/A1/A1.docx
Normal file
BIN
Assignments/As1/A1/A1.pdf
Normal file
BIN
Assignments/As1/A1/IsaacShoebottom_A1.pdf
Normal file
1
Assignments/As1/A1/Problem14.drawio
Normal file
@ -0,0 +1 @@
|
||||
<mxfile host="app.diagrams.net" modified="2021-01-24T23:02:32.827Z" agent="5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36 Edg/87.0.664.75" etag="YfNNgj2tCaFOySm-v3W8" version="14.2.7" type="device"><diagram id="PVQmGwHn-0BxfbdsLOLP" name="Page-1">7Vtdc5s6EP01frwdQJCPxxrb93aSTjtOZ9o8Kka2dQcjBuTY7q/vCiSDkUlIU4xwPeMHtEhC2nM4u6xhgPzV9t8Ex8vPLCDhwLGC7QCNBo5ju44zED8r2OWW6ytpWCQ0kJ0KwwP9SaTRktY1DUh60JEzFnIaHxpnLIrIjB/YcJKwzWG3OQsPrxrjBdEMDzMc6tbvNODL3HrjWYX9P0IXS3Vl25JnVlh1loZ0iQO2KZnQeID8hDGeH622PgmF85Rf8nGTmrP7hSUk4k0GTK7Xj7Z/a1MLfWGx9/+IpJt/5CzPOFzLDT/A1lMwTUmckBTmxpw+E7kFvlN+gd3E4pDjJ2EaphwnXMKHLDAAIBzTiCRgsLN2GOI4pVn33LKkYXCPd2zN1USqNZzTLQmmOXqiLwB5D5OJpph8DpM/yMWI0zikiwiOZ7BeccUhLB3Wco9TLnvIfZKEk22tA+09LMBnwlaEJzvoIgcgBbqksiubm4IX9o20LcucUJTAkouL/dQFXHAgEXsDeo6GXi1OsE1OcTiFewRHiwyyQ0SEW4OExd9wsiBcGmJGhUPHz+Cive9pGPosZALYiEViJs5ieTIkczX2iXHOVgo/6Y79pJkrvCH8wDm+9cEbeLBcH9p20Yaf6J5wn0UpT4BOYg4CqG6IQLYZqvXE16GW0KKG0KK2kEUasl/v3oZtJoe4wPbNsFkV2Kr3HAO3z8NM0ZY0CEj0Ljyc43iUAECn9L97XBdBFD+NOsZBaV3ed5jGeEajxX0+8qoClHcqoLaD2hvHOyVwXi8ksYppDyTxqmtJvNKQnXQtiSSgar4/r4ieWYp4rbn/U/TM6IyYL4gnwcUUAbT10DUiAoiV2NYljXduTMvi7X7ELDPTeNfsPN7Wo9aZJ/K2YXHL1gNXoYfmx652k/k6sIwJZje9kEYz0/mXpbHzfN6+/csS+pzM5iijKkz3sshxGmhM0UGn9ukrvaT0emUeOU2T+vYQ60fkMjKpz9lublLv6JHrzJN6x7DQhfTQ1ZtqVMvlecMjGdLLUybqopEZ/Su62HlGj/RC1uTOPueUHtU8Y3Wmi3q5yV+n4BiSmC+Mp4HGGCHUU/qLEP4ZIbztXAj15H9y90Z4eyaENYh0JoR6iv631jbqoDFFCF09l1cx61LcGGj/V+5rHd39Yenqb42aGLqMrG241nGwTaltuI6G7ZnXNtya26+zVw/1dz/7k8O3W9yog8qYUHYpbrQljJ0XN9xjxY1zTuldw2obrl7b6E3N9zTImCKDno6UBlAWKPK83Ya9DJd8FUoakyj4KL7cguZ4CnB8Y59xtBMntpT/EC7/4MnWoxoCx6OtuitEY6caEeyoNEg0H8vnimFZS43LHiwOlqGMEyq8kXXKd0UC7ROySm4PO2frZEZe8Jn6tk2JfV2/utJHGWzrpaeBhIT5F13l5R2jgLzGVxEcSuS6rrw+6VZYlO9UjiqIpE3kVv6zdbzKRLkrtIkyRu43/g6SNqi/CWRVNgOIUr6bZt5j0bg4M3wPle0SkQtav0blAyIXvDaEym5TLjeonveEy5WJUHWitrnc4GWD9rhc4dcKR8GXjGO/S9jfuzmCloTZa6rMFzK/QmZoFp87592Lj8bR+Bc=</diagram></mxfile>
|
BIN
Assignments/As1/A1/Problem14.png
Normal file
After Width: | Height: | Size: 18 KiB |
1
Assignments/As1/A1/Problem16c.drawio
Normal file
@ -0,0 +1 @@
|
||||
<mxfile host="app.diagrams.net" modified="2021-01-24T23:07:19.546Z" agent="5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36 Edg/87.0.664.75" etag="U-XtbTUxuImycHJ_2PWi" version="14.2.7" type="device"><diagram id="rIFoBojoA3rnt8gzCeNP" name="Page-1">7Vltb5swEP41+biKl9B0H5uXdlOzqUonrf3oBgc8GZsZp4H9+p2xHQiEqlXXhGyT+MA9Pp/te467Awb+JMmvBUrjLzzEdOA5YT7wpwPPc4eeN1CXExYaGblDDUSChEapAu7IL2xAx6BrEuJsR1FyTiVJd8ElZwwv5Q6GhOCbXbUVp7urpijCLeBuiWgb/U5CGWv0InAq/BMmUWxXdh0zkiCrbIAsRiHf1CB/NvAngnOp75J8gqlynvWLnnfVMbrdmMBMvmTC/eXoJhpJdpfgh+n1z8mPafH1g7HyhOjaHPiSCEoYFpnZtSysK+AAqbqV6FFB40wiIQ1jvgMAcCCRmguAW8qUojQjpbpGYkLDOSr4WlpDVhqvSI7DhSZM6QJ3czCmRGV8BcbvzGbUMKIkYnC/hOOrFccCZ7CXOcqk0TBHw0LivNNn7pYJCGHMEyxFASpmwshwZ4L3woibKhJci8X1KLBBgEz0RVvLFUFwYzh6BV9ei69OmuCUkiC6gKcCsahkbJcQ5dVQ8PQbEhGWBkg5Uf6cPYGHtq4nlE445YpXxpmyJHlqBile2bmPXEqeWPqMO7ZGS1cEY7jAORPnLBgEsN0JyG4lw6XUhZxwlkkB0aRsYCB1gxWxLyO1O9TbTBtq/RdS678Xs36L2dub13FbJkBUcftq2pwGbc1HjoPbV7TMYTEJQ8zexIe3n48aAf4h/T/szISfp0fmwaY6rTvOUrQkLJrrmecNooJDEZV3PzjBIYkLTiIlNjk9gZR4fuyUeN5i9urYKRGHxNr78xkx6FdGHLXdT9Wy/c+HB6GlL/nPbVcuzdP/Dh5Ghl7QsxbePY2C1c8eftjvJt5tl6y/vIt3e1a03NOtWu/bxXcR1ZsydnESabGfffzzafHojbz78R/r5HUw9ycr2m/QJ/l14zDU9CUPeu0C1iIIhxG2lQJOS2SxwBRJwtmsGtH1RDf3Lpx4HMuEmmjHLLxUP0dAnC0SxAqNXRG1V/145ETeW224f1D4WWCkaV5TmxZWYOCA+7pQm6XEalop2Xnla0i1Hx1EJVjbkHaCOnkn3wbK+Fos8XMu1nrSFoc39Dbb14S97w6iZOVpd8f7IsascauKSS0WG78fhl4j6PRJzSyv9uunYWjYMOQ3DWlXtAyVAbw9+L6YBrH6g6XVq/+A/uw3</diagram></mxfile>
|
BIN
Assignments/As1/A1/Problem16c.png
Normal file
After Width: | Height: | Size: 7.0 KiB |
1
Assignments/As1/A1/Problem16d.drawio
Normal file
@ -0,0 +1 @@
|
||||
<mxfile host="app.diagrams.net" modified="2021-01-24T23:34:05.381Z" agent="5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36 Edg/87.0.664.75" etag="eQ6dm_gG3a-hJiBuqIk8" version="14.2.7" type="device"><diagram id="_sWjUXGLdLXe9Hf45Elt" name="Page-1">7VvbctsqFP0aP7ajq+M+1o7TWzLTcTpzmvNGLCwzg4WKcGL16w8I0A3LsU99QWlm/CC2YAv2Wlp7I8kDf7LafKIgXd6RCOKB50SbgX898Dw38LyB+DlRLi1XbiANMUWR6lQZ7tFvqIyOsq5RBLNGR0YIZihtGuckSeCcNWyAUvLc7LYguHnVFMTQMNzPATat/6CILaV1FDqV/TNE8VJf2XXUmRXQnZUhW4KIPNdM/nTgTyghTB6tNhOIRfB0XOS4m46z5cQoTNg+Az5/hL9m/5KHxe/HK5qnwdc7dvNOeXkCeK0WPCE0JRQwRBI1b5brYPAlpOKQgUdhGmcMUKYw8x1u4CgwgBJIucEt2hiDNENFd2lZIhzdgpysmXakW+MF2sBoJiETfTl6t9yZaArnC+78Xk1GnAYYxQk/nvMAiCuOKcz4XG5BxlQPtThIGdx0Rs0tseAkhmQFGc15FzVAA503m88VF9yRsi3rPNA0AIp/cem5gogfKJQOQMwzEOuEia+SIYBn/L4ASVwg1gRERDWiJP0BaAyZMqQEiXhOn3iEytAjjCcEE4FrQhLhiZFUncRwocc+EsbISsOnwlE6LUIRjvmPB2fivA8HIZ/uhLfdqs1/ojtlE5JkjHI2CR+Qg/oMBbD7gdpNdhNpBa2/J7T+qZD1DWS/fzsM20ICQYXtwbA5LdjatxzhYV/gQsWWKIpg8kd4eNvxqAHgnzP+wS4t/HJ9YSi02sm+4ywFc5TEt3LksIVVeC6sNt33TnhO7MJeqGIb0x6o4vDSqjg0kL25tCrCCGl/xxfF0C5RvDLDD+aM0Nx+QTwLLrYIoGtmLwXUWxXPwx7YVsa7/chYdtbxgd2FvGvmrFdeybuWZS23x2nrtHV8F1LW5LFRL3TRzkp+ty5evJR3P/xltbwksz2yqB9F9/URx3nQsUUKPTOJzWD89lxeipl1Fb3Xj8xlZUUvqW5vRe+ZmeuVV/SeZanLN1OXFEP7s9aJH8xbnsV88xWzjbJoZUH/gixevKD3vb+soPc7ipKLqaL5zlg+52A9eNBxHmhs0cHATGDTVYpJDuFbPW8+oT9OQa8uVzG983r+FoJ82IMfAPOYJIDBMVknUWbQpFzpHzCnHxnUyo1F4GxnnS0bi8DMoK98YxFYlkIDM4VqXbY/hZ52a9EFlTUp1XznbaMwWrm1eEEYL761CMz34697axF0vLy5mC5u+fCqL69Qz4OMLTIYmhnMAAhGMdSJgq8WsXwGcfHWZ1qdkelEbjNcvuLxkq2wIjtMoo/i7xS8OZ1x0H6QO5Dk8sQNEhOWt0jCV/Sz3ngQjfehbl5v6ievc93aIPZTX4of10bxVjVINPSYYlfUmJQ21iYkIyGW3wm6MmVkTedwR5xVVJlOEF399vgYoty0bN3J0AKap+aMd2xvvouEUiPkVXNrE3gt5smVqlEV+QxHQcuR33YkQ2E4OtbGJ9wjv5+O2HvRS/PWOYC35T3iHnaPHJPKo55wORw1KegO/yeXw2HLUVuOT83lPb73OxpLKxWuSPXQ4NRuFa4Y/FDT5B0qfBrB1d+0vsjSrmL2TXFLlvJm9VdD2b36w6Y//Q8=</diagram></mxfile>
|
BIN
Assignments/As1/A1/Problem16d.png
Normal file
After Width: | Height: | Size: 18 KiB |
BIN
Assignments/As3/A3.pdf
Normal file
BIN
Assignments/As3/IsaacShoebottom_A3.docx
Normal file
BIN
Assignments/As3/IsaacShoebottom_A3.pdf
Normal file
BIN
Assignments/As4/A4.pdf
Normal file
BIN
Assignments/As4/IsaacShoebottom_As4.docx
Normal file
BIN
Assignments/As4/IsaacShoebottom_As4.pdf
Normal file
5
Assignments/As4/Problem101.sql
Normal file
@ -0,0 +1,5 @@
|
||||
select PATRON.PAT_ID, PAT_FNAME, PAT_LNAME
|
||||
from PATRON
|
||||
left join CHECKOUT on PATRON.PAT_ID = CHECKOUT.PAT_ID
|
||||
where CHECK_NUM is NULL
|
||||
order by PAT_LNAME, PAT_FNAME;
|
3
Assignments/As4/Problem60.sql
Normal file
@ -0,0 +1,3 @@
|
||||
SELECT BOOK_YEAR
|
||||
FROM BOOK
|
||||
GROUP BY BOOK_YEAR;
|
3
Assignments/As4/Problem61.sql
Normal file
@ -0,0 +1,3 @@
|
||||
select BOOK_SUBJECT
|
||||
from BOOK
|
||||
group by BOOK_SUBJECT;
|
4
Assignments/As4/Problem65.sql
Normal file
@ -0,0 +1,4 @@
|
||||
select BOOK_NUM, BOOK_TITLE, BOOK_COST
|
||||
from BOOK
|
||||
where BOOK_COST = 59.95
|
||||
order by BOOK_NUM;
|
4
Assignments/As4/Problem72.sql
Normal file
@ -0,0 +1,4 @@
|
||||
select PAT_ID, PAT_FNAME, PAT_LNAME
|
||||
from PATRON
|
||||
where PAT_TYPE = 'student'
|
||||
order by PAT_ID;
|
4
Assignments/As4/Problem73.sql
Normal file
@ -0,0 +1,4 @@
|
||||
select PAT_ID, PAT_FNAME, PAT_LNAME, PAT_TYPE
|
||||
from PATRON
|
||||
where PAT_LNAME like 'c%'
|
||||
order by PAT_ID;
|
4
Assignments/As4/Problem74.sql
Normal file
@ -0,0 +1,4 @@
|
||||
select AU_ID, AU_FNAME, AU_LNAME
|
||||
from AUTHOR
|
||||
where AU_BIRTHYEAR is NULL
|
||||
order by AU_ID;
|
2
Assignments/As4/Problem78.sql
Normal file
@ -0,0 +1,2 @@
|
||||
select count(BOOK_NUM) as `Number of Books`
|
||||
from BOOK;
|
2
Assignments/As4/Problem79.sql
Normal file
@ -0,0 +1,2 @@
|
||||
select count(DISTINCT BOOK_SUBJECT) as `Number of Subjects`
|
||||
from BOOK;
|
3
Assignments/As4/Problem80.sql
Normal file
@ -0,0 +1,3 @@
|
||||
select count(BOOK_NUM) as `Available Books`
|
||||
from BOOK
|
||||
where PAT_ID is NULL;
|
2
Assignments/As4/Problem81.sql
Normal file
@ -0,0 +1,2 @@
|
||||
select max(BOOK_COST) as `Most Expensive`
|
||||
from BOOK;
|
2
Assignments/As4/Problem82.sql
Normal file
@ -0,0 +1,2 @@
|
||||
select min(BOOK_COST) as `Least Expensive`
|
||||
from BOOK;
|
2
Assignments/As4/Problem83.sql
Normal file
@ -0,0 +1,2 @@
|
||||
select count(DISTINCT PAT_ID) as `DIFFERENT PATRONS`
|
||||
from CHECKOUT;
|
4
Assignments/As4/Problem84.sql
Normal file
@ -0,0 +1,4 @@
|
||||
select BOOK_SUBJECT, count(BOOK_SUBJECT) as `Books In Subject`
|
||||
from BOOK
|
||||
group by BOOK_SUBJECT
|
||||
order by count(BOOK_SUBJECT) desc, BOOK_SUBJECT;
|
4
Assignments/As4/Problem85.sql
Normal file
@ -0,0 +1,4 @@
|
||||
select AU_ID, count(BOOK_NUM) as `Books Written`
|
||||
from WRITES
|
||||
group by AU_ID
|
||||
order by count(BOOK_NUM) desc, AU_ID;
|
BIN
Assignments/As5/A5.pdf
Normal file
36
Assignments/As5/Assignment5.sql
Normal file
@ -0,0 +1,36 @@
|
||||
CREATE TABLE JOB
|
||||
(
|
||||
JOB_CODE INT AUTO_INCREMENT,
|
||||
JOB_DESCRIPTION VARCHAR(25),
|
||||
JOB_CHG_HOUR DECIMAL(8,2),
|
||||
JOB_LAST_UPDATE DATETIME,
|
||||
PRIMARY KEY(JOB_CODE)
|
||||
);
|
||||
ALTER TABLE JOB AUTO_INCREMENT = 500;
|
||||
|
||||
|
||||
CREATE TABLE EMPLOYEE
|
||||
(
|
||||
EMP_NUM INT AUTO_INCREMENT,
|
||||
EMP_LNAME VARCHAR(15),
|
||||
EMP_FNAME VARCHAR(15),
|
||||
EMP_INITIAL VARCHAR(1),
|
||||
EMP_HIREDATE DATETIME,
|
||||
EMP_YEARS INT,
|
||||
JOB_CODE INT,
|
||||
PRIMARY KEY (EMP_NUM),
|
||||
FOREIGN KEY(JOB_CODE)
|
||||
REFERENCES JOB(JOB_CODE)
|
||||
ON DELETE NO ACTION
|
||||
ON UPDATE CASCADE
|
||||
);
|
||||
|
||||
ALTER TABLE EMPLOYEE AUTO_INCREMENT = 100;
|
||||
|
||||
INSERT INTO JOB(JOB_DESCRIPTION, JOB_CHG_HOUR, JOB_LAST_UPDATE) VALUES ("Programmer", 35.75, "2017-11-20");
|
||||
INSERT INTO JOB(JOB_DESCRIPTION, JOB_CHG_HOUR, JOB_LAST_UPDATE) VALUES ("Systems Analyst", 96.75, "2017-11-20");
|
||||
INSERT INTO JOB(JOB_DESCRIPTION, JOB_CHG_HOUR, JOB_LAST_UPDATE) VALUES ("Database Designer", 125.00, "2018-03-24");
|
||||
|
||||
INSERT INTO EMPLOYEE(EMP_LNAME, EMP_FNAME, EMP_INITIAL, EMP_HIREDATE, JOB_CODE, EMP_YEARS) VALUES ("News", "John", "G", "2000-11-08", 501, 4);
|
||||
INSERT INTO EMPLOYEE(EMP_LNAME, EMP_FNAME, EMP_INITIAL, EMP_HIREDATE, JOB_CODE, EMP_YEARS) VALUES ("Senior", "David", "H", "1989-07-12", 500, 15);
|
||||
INSERT INTO EMPLOYEE(EMP_LNAME, EMP_FNAME, EMP_INITIAL, EMP_HIREDATE, JOB_CODE, EMP_YEARS) VALUES ("Arbough", "June", "E", "1996-12-01", 502, 8);
|
BIN
Assignments/As5/IsaacShoebottom_As5.docx
Normal file
BIN
Assignments/As5/IsaacShoebottom_As5.pdf
Normal file
BIN
Assignments/As6/A6.pdf
Normal file
9
Assignments/As6/Create Table.sql
Normal file
@ -0,0 +1,9 @@
|
||||
DROP TABLE IF EXISTS schools;
|
||||
CREATE TABLE schools (
|
||||
schoolId INT NOT NULL AUTO_INCREMENT,
|
||||
name varchar(50) NOT NULL,
|
||||
province varchar(20) DEFAULT NULL,
|
||||
language char(2) DEFAULT NULL,
|
||||
level varchar(10) DEFAULT NULL,
|
||||
PRIMARY KEY (schoolId)
|
||||
);
|
BIN
Assignments/As6/IsaacShoebottom_As6.docx
Normal file
BIN
Assignments/As6/IsaacShoebottom_As6.pdf
Normal file
BIN
Assignments/As6/RickQAddData1.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
Assignments/As6/RickQChangeID2Manitoba.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
Assignments/As6/RickQDeleteManitoba.png
Normal file
After Width: | Height: | Size: 12 KiB |
6
Assignments/As6/add data.sql
Normal file
@ -0,0 +1,6 @@
|
||||
insert into schools (name, province, language, level) values ('University of New Brunswick', 'New Brunswick', 'EN', 'University');
|
||||
insert into schools (name, province, language, level) values ('Leo Hayes', 'New Brunswick', 'EN', 'High School');
|
||||
insert into schools (name, province, language, level) values ('Fredericton High School', 'New Brunswick', 'EN', 'High School');
|
||||
insert into schools (name, province, language, level) values ('Liverpool Elementary', 'New Brunswick', 'EN', 'Elementary');
|
||||
insert into schools (name, province, language, level) values ('Forest Hill', 'New Brunswick', 'EN', 'Elementary');
|
||||
insert into schools (name, province, language, level) values ('Bliss Carmen', 'New Brunswick', 'EN', 'Middle School');
|
1
Assignments/As6/change id 2.sql
Normal file
@ -0,0 +1 @@
|
||||
update schools set province = 'Manitoba' where (schoolId = 2);
|
1
Assignments/As6/delete manitoba.sql
Normal file
@ -0,0 +1 @@
|
||||
delete from schools where province = 'Manitoba';
|
BIN
Assignments/As7/A7.pdf
Normal file
BIN
Assignments/As7/IsaacShoebottom_As7.docx
Normal file
BIN
Assignments/As7/IsaacShoebottom_As7.pdf
Normal file
230
Labs/Lab1/IsaacShoebttom_Lab1.txt
Normal file
@ -0,0 +1,230 @@
|
||||
Script started on Thu 14 Jan 2021 05:26:15 PM AST
|
||||
]0;ishoebot@id414m12:~[ishoebot@id414m12 ~]$ mysql -h cs1103.cs.unb.ca -u <enter username> -pname> -p -p[K -p[K -p[K -p[K -p[K -p[K -p[K -p[K -p[K-p[K -p[K -p[K -p[K -p[K -p[K -p[Ki -ps -ph -po -pe -pb -po -pt -p
|
||||
Enter password:
|
||||
(B[0;1mWelcome to the MariaDB monitor. Commands end with ; or \g.
|
||||
(B[m(B[0;1mYour MariaDB connection id is 12752
|
||||
Server version: 5.5.65-MariaDB MariaDB Server
|
||||
|
||||
(B[m(B[0;1mCopyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
|
||||
|
||||
(B[m(B[0;1mType 'help;' or '\h' for help. Type '\c' to clear the current input statement.
|
||||
|
||||
(B[m[?1034hMariaDB [(none)]> show ta[K[Kdatabases
|
||||
-> ;
|
||||
+----------------------+
|
||||
| Database |
|
||||
+----------------------+
|
||||
| information_schema |
|
||||
| Ch01_Problems |
|
||||
| Ch01_Text |
|
||||
| Ch02_DealCo |
|
||||
| Ch02_InsureCo |
|
||||
| Ch02_SaleCo |
|
||||
| Ch02_TinyCollege |
|
||||
| Ch03_AviaCo |
|
||||
| Ch03_BeneCo |
|
||||
| Ch03_CheapCo |
|
||||
| Ch03_CollegeQue |
|
||||
| Ch03_CollegeTry |
|
||||
| Ch03_CollegeTry2 |
|
||||
| Ch03_InsureCo |
|
||||
| Ch03_Museum |
|
||||
| Ch03_NoComp |
|
||||
| Ch03_Relational_DB |
|
||||
| Ch03_SaleCo |
|
||||
| Ch03_StoreCo |
|
||||
| Ch03_Theatre |
|
||||
| Ch03_TinyCollege |
|
||||
| Ch03_TransCo |
|
||||
| Ch03_VendingCo |
|
||||
| Ch04_Clinic |
|
||||
| Ch04_CollegeTry |
|
||||
| Ch04_PartCo |
|
||||
| Ch04_ShortCo |
|
||||
| Ch04_TinyCollege |
|
||||
| Ch04_TinyCollege_Alt |
|
||||
| Ch07_ConstructCo |
|
||||
| Ch07_Fact |
|
||||
| Ch07_LargeCo |
|
||||
| Ch07_SaleCo |
|
||||
| ishoebot |
|
||||
+----------------------+
|
||||
(B[0;1m34 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [(none)]> s[Kuse Ch01_Text
|
||||
Reading table information for completion of table and column names
|
||||
You can turn off this feature to get a quicker startup with -A
|
||||
|
||||
(B[0;1mDatabase changed
|
||||
(B[mMariaDB [Ch01_Text]> show columns from [K[K[K[K[K[K[K[K[K[K[K[K[K[K[K[K[K[Kshow tables;
|
||||
+---------------------+
|
||||
| Tables_in_Ch01_Text |
|
||||
+---------------------+
|
||||
| AGENT |
|
||||
| CERTIFIED |
|
||||
| CUSTOMER |
|
||||
| EMPLOYEE |
|
||||
| EMPLOYEESKILLS |
|
||||
| SKILL |
|
||||
+---------------------+
|
||||
(B[0;1m6 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columnds from[K[K[K[K[K[K[K[K[K[K[Klom[Kum[K[K[Kumns from AGENT
|
||||
-> ;
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
| A_NAME | varchar(15) | YES | | NULL | |
|
||||
| A_PHONE | varchar(12) | YES | | NULL | |
|
||||
| A_ADDRESS | varchar(20) | YES | | NULL | |
|
||||
| ZIP | varchar(5) | YES | | NULL | |
|
||||
| HIRED | datetime | YES | | NULL | |
|
||||
| YTD_PAY | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_FIT | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_FICA | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_SLS | decimal(10,2) | YES | | NULL | |
|
||||
| DEP | int(11) | YES | | NULL | |
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
(B[0;1m10 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> select * from AGENT
|
||||
-> ;
|
||||
+--------------+--------------+--------------------+-------+---------------------+----------+---------+----------+-----------+------+
|
||||
| A_NAME | A_PHONE | A_ADDRESS | ZIP | HIRED | YTD_PAY | YTD_FIT | YTD_FICA | YTD_SLS | DEP |
|
||||
+--------------+--------------+--------------------+-------+---------------------+----------+---------+----------+-----------+------+
|
||||
| Alex B. Alby | 713-228-1249 | 123 Toll, Nash, TN | 37119 | 2002-11-01 00:00:00 | 26566.24 | 6641.56 | 2125.30 | 132735.75 | 3 |
|
||||
| Leah F. Hahn | 615-882-1244 | 334 Main, Fox, KY | 25246 | 1988-05-23 00:00:00 | 32213.76 | 8053.44 | 2577.10 | 138967.35 | 0 |
|
||||
| John T. Okon | 615-123-5589 | 452 Elm, New, TN | 36155 | 2007-06-15 00:00:00 | 23198.29 | 5799.57 | 1855.86 | 127093.45 | 2 |
|
||||
+--------------+--------------+--------------------+-------+---------------------+----------+---------+----------+-----------+------+
|
||||
(B[0;1m3 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columnds from EMPLOYEE
|
||||
-> ;
|
||||
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'columnds from EMPLOYEE' at line 1
|
||||
(B[0;7m(B[mMariaDB [Ch01_Text]> ;show columnds from EMPLOYEE
[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C;[Kshow columnds from EMPLOYEE[1P[1P[1@s
|
||||
-> ;
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| EMPLOYEE_ID | varchar(6) | NO | PRI | NULL | |
|
||||
| EMPLOYEE_FNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_LNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_HIREDATE | datetime | YES | | NULL | |
|
||||
| EMPLOYEE_TITLE | varchar(30) | YES | | NULL | |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
(B[0;1m5 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> select * from EMPLOYEE
|
||||
-> ;
|
||||
+-------------+----------------+----------------+---------------------+---------------------+
|
||||
| EMPLOYEE_ID | EMPLOYEE_FNAME | EMPLOYEE_LNAME | EMPLOYEE_HIREDATE | EMPLOYEE_TITLE |
|
||||
+-------------+----------------+----------------+---------------------+---------------------+
|
||||
| 02345 | Johnny | Jones | 1997-02-14 00:00:00 | DBA |
|
||||
| 03373 | Franklin | Johnson | 2004-03-15 00:00:00 | Purchasing Agent |
|
||||
| 04893 | Patricia | Richards | 2006-06-11 00:00:00 | DBA |
|
||||
| 06234 | Jasmine | Patel | 2007-08-10 00:00:00 | Programmer |
|
||||
| 08273 | Marco | Bienz | 2008-07-28 00:00:00 | Analyst |
|
||||
| 09002 | Ben | Joiner | 2012-05-20 00:00:00 | Clerk |
|
||||
| 09283 | Juan | Chavez | 2012-07-04 00:00:00 | Clerk |
|
||||
| 09382 | Jessica | Johnson | 2012-08-02 00:00:00 | Database Programmer |
|
||||
| 10282 | Amanda | Richardson | 2013-04-11 00:00:00 | Clerk |
|
||||
| 13383 | Raymond | Matthews | 2014-03-12 00:00:00 | Programmer |
|
||||
| 13567 | Robert | Almond | 2014-09-30 00:00:00 | Analyst |
|
||||
| 13932 | Megan | Lee | 2015-09-29 00:00:00 | Programmer |
|
||||
| 14311 | Lee | Duong | 2014-09-01 00:00:00 | Programmer |
|
||||
+-------------+----------------+----------------+---------------------+---------------------+
|
||||
(B[0;1m13 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> select EMPLOYEE_ID [K, EMPLOYEE_TITLE from EMPLOYEE
|
||||
-> ;
|
||||
+-------------+---------------------+
|
||||
| EMPLOYEE_ID | EMPLOYEE_TITLE |
|
||||
+-------------+---------------------+
|
||||
| 02345 | DBA |
|
||||
| 03373 | Purchasing Agent |
|
||||
| 04893 | DBA |
|
||||
| 06234 | Programmer |
|
||||
| 08273 | Analyst |
|
||||
| 09002 | Clerk |
|
||||
| 09283 | Clerk |
|
||||
| 09382 | Database Programmer |
|
||||
| 10282 | Clerk |
|
||||
| 13383 | Programmer |
|
||||
| 13567 | Analyst |
|
||||
| 13932 | Programmer |
|
||||
| 14311 | Programmer |
|
||||
+-------------+---------------------+
|
||||
(B[0;1m13 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show col[K[K[K[K[K[K[Khow columns from EMPLOYEE
|
||||
-> ;
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| EMPLOYEE_ID | varchar(6) | NO | PRI | NULL | |
|
||||
| EMPLOYEE_FNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_LNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_HIREDATE | datetime | YES | | NULL | |
|
||||
| EMPLOYEE_TITLE | varchar(30) | YES | | NULL | |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
(B[0;1m5 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> list cus[K[K[KCu[K[K[K[K[K[K[Kshow tables
|
||||
-> ;
|
||||
+---------------------+
|
||||
| Tables_in_Ch01_Text |
|
||||
+---------------------+
|
||||
| AGENT |
|
||||
| CERTIFIED |
|
||||
| CUSTOMER |
|
||||
| EMPLOYEE |
|
||||
| EMPLOYEESKILLS |
|
||||
| SKILL |
|
||||
+---------------------+
|
||||
(B[0;1m6 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columnds from CUSTOMER
|
||||
-> ;
|
||||
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'columnds from CUSTOMER' at line 1
|
||||
(B[0;7m(B[mMariaDB [Ch01_Text]> ;show columnds from CUSTOMER[C[C[1P[1P[1@s
|
||||
-> ;
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
| C_NAME | varchar(20) | YES | | NULL | |
|
||||
| C_PHONE | varchar(12) | YES | | NULL | |
|
||||
| C_ADDRESS | varchar(30) | YES | | NULL | |
|
||||
| C_ZIP | varchar(5) | YES | | NULL | |
|
||||
| A_NAME | varchar(20) | YES | | NULL | |
|
||||
| A_PHONE | varchar(12) | YES | | NULL | |
|
||||
| TP | varchar(2) | YES | | NULL | |
|
||||
| AMT | decimal(6,2) | YES | | NULL | |
|
||||
| REN | datetime | YES | | NULL | |
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
(B[0;1m9 rows in set (0.01 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> list C_NAME [K, C_P[KADDRESS [K, C_PHONE from CUSTOMER;
|
||||
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'list C_NAME, C_ADDRESS, C_PHONE from CUSTOMER' at line 1
|
||||
(B[0;7m(B[mMariaDB [Ch01_Text]> list C_NAME, C_ADDRESS, C_PHONE from CUSTOMER;[C[C[C[C[1P[1P[1P[1P[1@s[1@e[1@l[1@e[1@c[1@t
|
||||
+-----------------+------------------------+--------------+
|
||||
| C_NAME | C_ADDRESS | C_PHONE |
|
||||
+-----------------+------------------------+--------------+
|
||||
| Alfred A. Ramas | 218 Fork Rd., Babs, TN | 615-844-2573 |
|
||||
| Leona K. Dunne | Box 12A, Fox, KY | 713-894-1238 |
|
||||
| Kathy W. Smith | 125 Oak Ln, Babs, TN | 615-894-2285 |
|
||||
| Paul F. Olowski | 217 Lee Ln., Babs, TN | 615-894-2180 |
|
||||
| Myron Orlando | Box 111, New, TN | 615-222-1672 |
|
||||
| Amy B. O'Brian | 387 Troll Dr., Fox, KY | 713-442-3381 |
|
||||
| James G. Brown | 21 Tye Rd., Nash, TN | 615-297-1228 |
|
||||
| George Williams | 155 Maple, Nash, TN | 615-290-2556 |
|
||||
| Anne G. Farriss | 2119 Elm, Crew, KY | 713-382-7185 |
|
||||
| Olette K. Smith | 2782 Main, Nash, TN | 615-297-3809 |
|
||||
+-----------------+------------------------+--------------+
|
||||
(B[0;1m10 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> exit
|
||||
(B[0;1mBye
|
||||
(B[m]0;ishoebot@id414m12:~[ishoebot@id414m12 ~]$ exit
|
||||
exit
|
||||
|
||||
Script done on Thu 14 Jan 2021 05:33:52 PM AST
|
BIN
Labs/Lab1/Lab1 - DBMS Environment.pdf
Normal file
231
Labs/Lab1/transcript.txt
Normal file
@ -0,0 +1,231 @@
|
||||
Script started on Thu 14 Jan 2021 05:08:01 PM AST
|
||||
]0;ishoebot@id414m35:~[ishoebot@id414m35 ~]$ exitls[Kexit[Kexitls[Kexit[Kmysql -h cs1103.cs.unb.ca -u <enter username> -p -p[K -p[K -p[K -p[K -p[K -p[K -p[K -p[K -p[K-p[K -p[K -p[K -p[K -p[K -p[K -p[Ki -ps -ph -po -pe -pb -po -pt -p
|
||||
Enter password:
|
||||
(B[0;1mWelcome to the MariaDB monitor. Commands end with ; or \g.
|
||||
(B[m(B[0;1mYour MariaDB connection id is 12655
|
||||
Server version: 5.5.65-MariaDB MariaDB Server
|
||||
|
||||
(B[m(B[0;1mCopyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
|
||||
|
||||
(B[m(B[0;1mType 'help;' or '\h' for help. Type '\c' to clear the current input statement.
|
||||
|
||||
(B[m[?1034hMariaDB [(none)]> 5show [K[K[K[K[K[Kshow databax[Kses
|
||||
-> ;
|
||||
+----------------------+
|
||||
| Database |
|
||||
+----------------------+
|
||||
| information_schema |
|
||||
| Ch01_Problems |
|
||||
| Ch01_Text |
|
||||
| Ch02_DealCo |
|
||||
| Ch02_InsureCo |
|
||||
| Ch02_SaleCo |
|
||||
| Ch02_TinyCollege |
|
||||
| Ch03_AviaCo |
|
||||
| Ch03_BeneCo |
|
||||
| Ch03_CheapCo |
|
||||
| Ch03_CollegeQue |
|
||||
| Ch03_CollegeTry |
|
||||
| Ch03_CollegeTry2 |
|
||||
| Ch03_InsureCo |
|
||||
| Ch03_Museum |
|
||||
| Ch03_NoComp |
|
||||
| Ch03_Relational_DB |
|
||||
| Ch03_SaleCo |
|
||||
| Ch03_StoreCo |
|
||||
| Ch03_Theatre |
|
||||
| Ch03_TinyCollege |
|
||||
| Ch03_TransCo |
|
||||
| Ch03_VendingCo |
|
||||
| Ch04_Clinic |
|
||||
| Ch04_CollegeTry |
|
||||
| Ch04_PartCo |
|
||||
| Ch04_ShortCo |
|
||||
| Ch04_TinyCollege |
|
||||
| Ch04_TinyCollege_Alt |
|
||||
| Ch07_ConstructCo |
|
||||
| Ch07_Fact |
|
||||
| Ch07_LargeCo |
|
||||
| Ch07_SaleCo |
|
||||
| ishoebot |
|
||||
+----------------------+
|
||||
(B[0;1m34 rows in set (0.01 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [(none)]> use Ch01_Text
|
||||
Reading table information for completion of table and column names
|
||||
You can turn off this feature to get a quicker startup with -A
|
||||
|
||||
(B[0;1mDatabase changed
|
||||
(B[mMariaDB [Ch01_Text]> show tables;
|
||||
+---------------------+
|
||||
| Tables_in_Ch01_Text |
|
||||
+---------------------+
|
||||
| AGENT |
|
||||
| CERTIFIED |
|
||||
| CUSTOMER |
|
||||
| EMPLOYEE |
|
||||
| EMPLOYEESKILLS |
|
||||
| SKILL |
|
||||
+---------------------+
|
||||
(B[0;1m6 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columns from AGENT
|
||||
-> ;
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
| A_NAME | varchar(15) | YES | | NULL | |
|
||||
| A_PHONE | varchar(12) | YES | | NULL | |
|
||||
| A_ADDRESS | varchar(20) | YES | | NULL | |
|
||||
| ZIP | varchar(5) | YES | | NULL | |
|
||||
| HIRED | datetime | YES | | NULL | |
|
||||
| YTD_PAY | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_FIT | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_FICA | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_SLS | decimal(10,2) | YES | | NULL | |
|
||||
| DEP | int(11) | YES | | NULL | |
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
(B[0;1m10 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> ;show columns from AGENT[K[K[K[K[KEMPLOYEE
|
||||
-> ;
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| EMPLOYEE_ID | varchar(6) | NO | PRI | NULL | |
|
||||
| EMPLOYEE_FNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_LNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_HIREDATE | datetime | YES | | NULL | |
|
||||
| EMPLOYEE_TITLE | varchar(30) | YES | | NULL | |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
(B[0;1m5 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> select EMPLOYEE_ID [K, EMPLOYEE_Ti[KITLE from EMPLOYEE
|
||||
-> ;.
|
||||
+-------------+---------------------+
|
||||
| EMPLOYEE_ID | EMPLOYEE_TITLE |
|
||||
+-------------+---------------------+
|
||||
| 02345 | DBA |
|
||||
| 03373 | Purchasing Agent |
|
||||
| 04893 | DBA |
|
||||
| 06234 | Programmer |
|
||||
| 08273 | Analyst |
|
||||
| 09002 | Clerk |
|
||||
| 09283 | Clerk |
|
||||
| 09382 | Database Programmer |
|
||||
| 10282 | Clerk |
|
||||
| 13383 | Programmer |
|
||||
| 13567 | Analyst |
|
||||
| 13932 | Programmer |
|
||||
| 14311 | Programmer |
|
||||
+-------------+---------------------+
|
||||
(B[0;1m13 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[m -> ;.[K
|
||||
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '.' at line 1
|
||||
(B[0;7m(B[mMariaDB [Ch01_Text]> ;.select EMPLOYEE_ID, EMPLOYEE_TITLE from EMPLOYEE;
|
||||
+-------------+---------------------+
|
||||
| EMPLOYEE_ID | EMPLOYEE_TITLE |
|
||||
+-------------+---------------------+
|
||||
| 02345 | DBA |
|
||||
| 03373 | Purchasing Agent |
|
||||
| 04893 | DBA |
|
||||
| 06234 | Programmer |
|
||||
| 08273 | Analyst |
|
||||
| 09002 | Clerk |
|
||||
| 09283 | Clerk |
|
||||
| 09382 | Database Programmer |
|
||||
| 10282 | Clerk |
|
||||
| 13383 | Programmer |
|
||||
| 13567 | Analyst |
|
||||
| 13932 | Programmer |
|
||||
| 14311 | Programmer |
|
||||
+-------------+---------------------+
|
||||
(B[0;1m13 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columns from AGENT
|
||||
-> ;
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
| A_NAME | varchar(15) | YES | | NULL | |
|
||||
| A_PHONE | varchar(12) | YES | | NULL | |
|
||||
| A_ADDRESS | varchar(20) | YES | | NULL | |
|
||||
| ZIP | varchar(5) | YES | | NULL | |
|
||||
| HIRED | datetime | YES | | NULL | |
|
||||
| YTD_PAY | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_FIT | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_FICA | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_SLS | decimal(10,2) | YES | | NULL | |
|
||||
| DEP | int(11) | YES | | NULL | |
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
(B[0;1m10 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> S[Kselect A_NAME [K, A-[K_P[KAd[KDDRESS [K, A_e[KPh[KHONE from AG
|
||||
AGAINST AGENT AGENT.A_ADDRESS AGENT.A_NAME AGENT.A_PHONE AGENT.DEP AGENT.HIRED AGENT.YTD_FICA AGENT.YTD_FIT AGENT.YTD_PAY AGENT.YTD_SLS AGENT.ZIP AGGREGATE
|
||||
MariaDB [Ch01_Text]> select A_NAME, A_ADDRESS, A_PHONE from AGENT
|
||||
-> ;
|
||||
+--------------+--------------------+--------------+
|
||||
| A_NAME | A_ADDRESS | A_PHONE |
|
||||
+--------------+--------------------+--------------+
|
||||
| Alex B. Alby | 123 Toll, Nash, TN | 713-228-1249 |
|
||||
| Leah F. Hahn | 334 Main, Fox, KY | 615-882-1244 |
|
||||
| John T. Okon | 452 Elm, New, TN | 615-123-5589 |
|
||||
+--------------+--------------------+--------------+
|
||||
(B[0;1m3 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show tables
|
||||
-> ;
|
||||
+---------------------+
|
||||
| Tables_in_Ch01_Text |
|
||||
+---------------------+
|
||||
| AGENT |
|
||||
| CERTIFIED |
|
||||
| CUSTOMER |
|
||||
| EMPLOYEE |
|
||||
| EMPLOYEESKILLS |
|
||||
| SKILL |
|
||||
+---------------------+
|
||||
(B[0;1m6 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columns from CUSTOMER
|
||||
-> ;
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
| C_NAME | varchar(20) | YES | | NULL | |
|
||||
| C_PHONE | varchar(12) | YES | | NULL | |
|
||||
| C_ADDRESS | varchar(30) | YES | | NULL | |
|
||||
| C_ZIP | varchar(5) | YES | | NULL | |
|
||||
| A_NAME | varchar(20) | YES | | NULL | |
|
||||
| A_PHONE | varchar(12) | YES | | NULL | |
|
||||
| TP | varchar(2) | YES | | NULL | |
|
||||
| AMT | decimal(6,2) | YES | | NULL | |
|
||||
| REN | datetime | YES | | NULL | |
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
(B[0;1m9 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> select A[KC_NAME [K, C-[K_Ad[KDDRESS [K, C_Po[Kh[KHONE from cus[K[K[KCUs[KSTOMER
|
||||
-> ;
|
||||
+-----------------+------------------------+--------------+
|
||||
| C_NAME | C_ADDRESS | C_PHONE |
|
||||
+-----------------+------------------------+--------------+
|
||||
| Alfred A. Ramas | 218 Fork Rd., Babs, TN | 615-844-2573 |
|
||||
| Leona K. Dunne | Box 12A, Fox, KY | 713-894-1238 |
|
||||
| Kathy W. Smith | 125 Oak Ln, Babs, TN | 615-894-2285 |
|
||||
| Paul F. Olowski | 217 Lee Ln., Babs, TN | 615-894-2180 |
|
||||
| Myron Orlando | Box 111, New, TN | 615-222-1672 |
|
||||
| Amy B. O'Brian | 387 Troll Dr., Fox, KY | 713-442-3381 |
|
||||
| James G. Brown | 21 Tye Rd., Nash, TN | 615-297-1228 |
|
||||
| George Williams | 155 Maple, Nash, TN | 615-290-2556 |
|
||||
| Anne G. Farriss | 2119 Elm, Crew, KY | 713-382-7185 |
|
||||
| Olette K. Smith | 2782 Main, Nash, TN | 615-297-3809 |
|
||||
+-----------------+------------------------+--------------+
|
||||
(B[0;1m10 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> exit;
|
||||
(B[0;1mBye
|
||||
(B[m]0;ishoebot@id414m35:~[ishoebot@id414m35 ~]$ exit
|
||||
exit
|
||||
|
||||
Script done on Thu 14 Jan 2021 05:18:31 PM AST
|
230
Labs/Lab1/transcript_v2.txt
Normal file
@ -0,0 +1,230 @@
|
||||
Script started on Thu 14 Jan 2021 05:26:15 PM AST
|
||||
]0;ishoebot@id414m12:~[ishoebot@id414m12 ~]$ mysql -h cs1103.cs.unb.ca -u <enter username> -pname> -p -p[K -p[K -p[K -p[K -p[K -p[K -p[K -p[K -p[K-p[K -p[K -p[K -p[K -p[K -p[K -p[Ki -ps -ph -po -pe -pb -po -pt -p
|
||||
Enter password:
|
||||
(B[0;1mWelcome to the MariaDB monitor. Commands end with ; or \g.
|
||||
(B[m(B[0;1mYour MariaDB connection id is 12752
|
||||
Server version: 5.5.65-MariaDB MariaDB Server
|
||||
|
||||
(B[m(B[0;1mCopyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
|
||||
|
||||
(B[m(B[0;1mType 'help;' or '\h' for help. Type '\c' to clear the current input statement.
|
||||
|
||||
(B[m[?1034hMariaDB [(none)]> show ta[K[Kdatabases
|
||||
-> ;
|
||||
+----------------------+
|
||||
| Database |
|
||||
+----------------------+
|
||||
| information_schema |
|
||||
| Ch01_Problems |
|
||||
| Ch01_Text |
|
||||
| Ch02_DealCo |
|
||||
| Ch02_InsureCo |
|
||||
| Ch02_SaleCo |
|
||||
| Ch02_TinyCollege |
|
||||
| Ch03_AviaCo |
|
||||
| Ch03_BeneCo |
|
||||
| Ch03_CheapCo |
|
||||
| Ch03_CollegeQue |
|
||||
| Ch03_CollegeTry |
|
||||
| Ch03_CollegeTry2 |
|
||||
| Ch03_InsureCo |
|
||||
| Ch03_Museum |
|
||||
| Ch03_NoComp |
|
||||
| Ch03_Relational_DB |
|
||||
| Ch03_SaleCo |
|
||||
| Ch03_StoreCo |
|
||||
| Ch03_Theatre |
|
||||
| Ch03_TinyCollege |
|
||||
| Ch03_TransCo |
|
||||
| Ch03_VendingCo |
|
||||
| Ch04_Clinic |
|
||||
| Ch04_CollegeTry |
|
||||
| Ch04_PartCo |
|
||||
| Ch04_ShortCo |
|
||||
| Ch04_TinyCollege |
|
||||
| Ch04_TinyCollege_Alt |
|
||||
| Ch07_ConstructCo |
|
||||
| Ch07_Fact |
|
||||
| Ch07_LargeCo |
|
||||
| Ch07_SaleCo |
|
||||
| ishoebot |
|
||||
+----------------------+
|
||||
(B[0;1m34 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [(none)]> s[Kuse Ch01_Text
|
||||
Reading table information for completion of table and column names
|
||||
You can turn off this feature to get a quicker startup with -A
|
||||
|
||||
(B[0;1mDatabase changed
|
||||
(B[mMariaDB [Ch01_Text]> show columns from [K[K[K[K[K[K[K[K[K[K[K[K[K[K[K[K[K[Kshow tables;
|
||||
+---------------------+
|
||||
| Tables_in_Ch01_Text |
|
||||
+---------------------+
|
||||
| AGENT |
|
||||
| CERTIFIED |
|
||||
| CUSTOMER |
|
||||
| EMPLOYEE |
|
||||
| EMPLOYEESKILLS |
|
||||
| SKILL |
|
||||
+---------------------+
|
||||
(B[0;1m6 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columnds from[K[K[K[K[K[K[K[K[K[K[Klom[Kum[K[K[Kumns from AGENT
|
||||
-> ;
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
| A_NAME | varchar(15) | YES | | NULL | |
|
||||
| A_PHONE | varchar(12) | YES | | NULL | |
|
||||
| A_ADDRESS | varchar(20) | YES | | NULL | |
|
||||
| ZIP | varchar(5) | YES | | NULL | |
|
||||
| HIRED | datetime | YES | | NULL | |
|
||||
| YTD_PAY | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_FIT | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_FICA | decimal(10,2) | YES | | NULL | |
|
||||
| YTD_SLS | decimal(10,2) | YES | | NULL | |
|
||||
| DEP | int(11) | YES | | NULL | |
|
||||
+-----------+---------------+------+-----+---------+-------+
|
||||
(B[0;1m10 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> select * from AGENT
|
||||
-> ;
|
||||
+--------------+--------------+--------------------+-------+---------------------+----------+---------+----------+-----------+------+
|
||||
| A_NAME | A_PHONE | A_ADDRESS | ZIP | HIRED | YTD_PAY | YTD_FIT | YTD_FICA | YTD_SLS | DEP |
|
||||
+--------------+--------------+--------------------+-------+---------------------+----------+---------+----------+-----------+------+
|
||||
| Alex B. Alby | 713-228-1249 | 123 Toll, Nash, TN | 37119 | 2002-11-01 00:00:00 | 26566.24 | 6641.56 | 2125.30 | 132735.75 | 3 |
|
||||
| Leah F. Hahn | 615-882-1244 | 334 Main, Fox, KY | 25246 | 1988-05-23 00:00:00 | 32213.76 | 8053.44 | 2577.10 | 138967.35 | 0 |
|
||||
| John T. Okon | 615-123-5589 | 452 Elm, New, TN | 36155 | 2007-06-15 00:00:00 | 23198.29 | 5799.57 | 1855.86 | 127093.45 | 2 |
|
||||
+--------------+--------------+--------------------+-------+---------------------+----------+---------+----------+-----------+------+
|
||||
(B[0;1m3 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columnds from EMPLOYEE
|
||||
-> ;
|
||||
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'columnds from EMPLOYEE' at line 1
|
||||
(B[0;7m(B[mMariaDB [Ch01_Text]> ;show columnds from EMPLOYEE
[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C[C;[Kshow columnds from EMPLOYEE[1P[1P[1@s
|
||||
-> ;
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| EMPLOYEE_ID | varchar(6) | NO | PRI | NULL | |
|
||||
| EMPLOYEE_FNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_LNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_HIREDATE | datetime | YES | | NULL | |
|
||||
| EMPLOYEE_TITLE | varchar(30) | YES | | NULL | |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
(B[0;1m5 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> select * from EMPLOYEE
|
||||
-> ;
|
||||
+-------------+----------------+----------------+---------------------+---------------------+
|
||||
| EMPLOYEE_ID | EMPLOYEE_FNAME | EMPLOYEE_LNAME | EMPLOYEE_HIREDATE | EMPLOYEE_TITLE |
|
||||
+-------------+----------------+----------------+---------------------+---------------------+
|
||||
| 02345 | Johnny | Jones | 1997-02-14 00:00:00 | DBA |
|
||||
| 03373 | Franklin | Johnson | 2004-03-15 00:00:00 | Purchasing Agent |
|
||||
| 04893 | Patricia | Richards | 2006-06-11 00:00:00 | DBA |
|
||||
| 06234 | Jasmine | Patel | 2007-08-10 00:00:00 | Programmer |
|
||||
| 08273 | Marco | Bienz | 2008-07-28 00:00:00 | Analyst |
|
||||
| 09002 | Ben | Joiner | 2012-05-20 00:00:00 | Clerk |
|
||||
| 09283 | Juan | Chavez | 2012-07-04 00:00:00 | Clerk |
|
||||
| 09382 | Jessica | Johnson | 2012-08-02 00:00:00 | Database Programmer |
|
||||
| 10282 | Amanda | Richardson | 2013-04-11 00:00:00 | Clerk |
|
||||
| 13383 | Raymond | Matthews | 2014-03-12 00:00:00 | Programmer |
|
||||
| 13567 | Robert | Almond | 2014-09-30 00:00:00 | Analyst |
|
||||
| 13932 | Megan | Lee | 2015-09-29 00:00:00 | Programmer |
|
||||
| 14311 | Lee | Duong | 2014-09-01 00:00:00 | Programmer |
|
||||
+-------------+----------------+----------------+---------------------+---------------------+
|
||||
(B[0;1m13 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> select EMPLOYEE_ID [K, EMPLOYEE_TITLE from EMPLOYEE
|
||||
-> ;
|
||||
+-------------+---------------------+
|
||||
| EMPLOYEE_ID | EMPLOYEE_TITLE |
|
||||
+-------------+---------------------+
|
||||
| 02345 | DBA |
|
||||
| 03373 | Purchasing Agent |
|
||||
| 04893 | DBA |
|
||||
| 06234 | Programmer |
|
||||
| 08273 | Analyst |
|
||||
| 09002 | Clerk |
|
||||
| 09283 | Clerk |
|
||||
| 09382 | Database Programmer |
|
||||
| 10282 | Clerk |
|
||||
| 13383 | Programmer |
|
||||
| 13567 | Analyst |
|
||||
| 13932 | Programmer |
|
||||
| 14311 | Programmer |
|
||||
+-------------+---------------------+
|
||||
(B[0;1m13 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show col[K[K[K[K[K[K[Khow columns from EMPLOYEE
|
||||
-> ;
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
| EMPLOYEE_ID | varchar(6) | NO | PRI | NULL | |
|
||||
| EMPLOYEE_FNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_LNAME | varchar(20) | YES | | NULL | |
|
||||
| EMPLOYEE_HIREDATE | datetime | YES | | NULL | |
|
||||
| EMPLOYEE_TITLE | varchar(30) | YES | | NULL | |
|
||||
+-------------------+-------------+------+-----+---------+-------+
|
||||
(B[0;1m5 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> list cus[K[K[KCu[K[K[K[K[K[K[Kshow tables
|
||||
-> ;
|
||||
+---------------------+
|
||||
| Tables_in_Ch01_Text |
|
||||
+---------------------+
|
||||
| AGENT |
|
||||
| CERTIFIED |
|
||||
| CUSTOMER |
|
||||
| EMPLOYEE |
|
||||
| EMPLOYEESKILLS |
|
||||
| SKILL |
|
||||
+---------------------+
|
||||
(B[0;1m6 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> show columnds from CUSTOMER
|
||||
-> ;
|
||||
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'columnds from CUSTOMER' at line 1
|
||||
(B[0;7m(B[mMariaDB [Ch01_Text]> ;show columnds from CUSTOMER[C[C[1P[1P[1@s
|
||||
-> ;
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
| Field | Type | Null | Key | Default | Extra |
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
| C_NAME | varchar(20) | YES | | NULL | |
|
||||
| C_PHONE | varchar(12) | YES | | NULL | |
|
||||
| C_ADDRESS | varchar(30) | YES | | NULL | |
|
||||
| C_ZIP | varchar(5) | YES | | NULL | |
|
||||
| A_NAME | varchar(20) | YES | | NULL | |
|
||||
| A_PHONE | varchar(12) | YES | | NULL | |
|
||||
| TP | varchar(2) | YES | | NULL | |
|
||||
| AMT | decimal(6,2) | YES | | NULL | |
|
||||
| REN | datetime | YES | | NULL | |
|
||||
+-----------+--------------+------+-----+---------+-------+
|
||||
(B[0;1m9 rows in set (0.01 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> list C_NAME [K, C_P[KADDRESS [K, C_PHONE from CUSTOMER;
|
||||
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'list C_NAME, C_ADDRESS, C_PHONE from CUSTOMER' at line 1
|
||||
(B[0;7m(B[mMariaDB [Ch01_Text]> list C_NAME, C_ADDRESS, C_PHONE from CUSTOMER;[C[C[C[C[1P[1P[1P[1P[1@s[1@e[1@l[1@e[1@c[1@t
|
||||
+-----------------+------------------------+--------------+
|
||||
| C_NAME | C_ADDRESS | C_PHONE |
|
||||
+-----------------+------------------------+--------------+
|
||||
| Alfred A. Ramas | 218 Fork Rd., Babs, TN | 615-844-2573 |
|
||||
| Leona K. Dunne | Box 12A, Fox, KY | 713-894-1238 |
|
||||
| Kathy W. Smith | 125 Oak Ln, Babs, TN | 615-894-2285 |
|
||||
| Paul F. Olowski | 217 Lee Ln., Babs, TN | 615-894-2180 |
|
||||
| Myron Orlando | Box 111, New, TN | 615-222-1672 |
|
||||
| Amy B. O'Brian | 387 Troll Dr., Fox, KY | 713-442-3381 |
|
||||
| James G. Brown | 21 Tye Rd., Nash, TN | 615-297-1228 |
|
||||
| George Williams | 155 Maple, Nash, TN | 615-290-2556 |
|
||||
| Anne G. Farriss | 2119 Elm, Crew, KY | 713-382-7185 |
|
||||
| Olette K. Smith | 2782 Main, Nash, TN | 615-297-3809 |
|
||||
+-----------------+------------------------+--------------+
|
||||
(B[0;1m10 rows in set (0.00 sec)
|
||||
(B[m(B[0;1m
|
||||
(B[mMariaDB [Ch01_Text]> exit
|
||||
(B[0;1mBye
|
||||
(B[m]0;ishoebot@id414m12:~[ishoebot@id414m12 ~]$ exit
|
||||
exit
|
||||
|
||||
Script done on Thu 14 Jan 2021 05:33:52 PM AST
|
BIN
Labs/Lab10/IsaacShoebottom_CS1103_Lab10.docx
Normal file
BIN
Labs/Lab10/IsaacShoebottom_CS1103_Lab10.pdf
Normal file
BIN
Labs/Lab10/Lab10 - XML Web Services.pdf
Normal file
BIN
Labs/Lab10/Lab10.zip
Normal file
BIN
Labs/Lab10/getStatus.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
Labs/Lab10/numOfMethods.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
Labs/Lab2/Lab2 - ERD Software.pdf
Normal file
BIN
Labs/Lab2/Lab2.docx
Normal file
1
Labs/Lab2/Lab2.drawio
Normal file
@ -0,0 +1 @@
|
||||
<mxfile host="app.diagrams.net" modified="2021-01-21T21:18:56.984Z" agent="5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36 Edg/87.0.664.75" etag="HbJHqGCg1yvTsoIWctFC" version="14.2.6" type="device"><diagram id="0-UjUI5zx-0e33ZyQNgJ" name="Page-1">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</diagram></mxfile>
|
BIN
Labs/Lab2/Lab2.png
Normal file
After Width: | Height: | Size: 33 KiB |
BIN
Labs/Lab2/Lab2_IsaacShoebottom.pdf
Normal file
BIN
Labs/Lab3/Lab3 - ERD Construction.pdf
Normal file
BIN
Labs/Lab3/Lab3.docx
Normal file
BIN
Labs/Lab3/Lab3.pdf
Normal file
BIN
Labs/Lab3/Lab3.png
Normal file
After Width: | Height: | Size: 41 KiB |
BIN
Labs/Lab4/Lab4 - Simple Queries.pdf
Normal file
BIN
Labs/Lab4/Lab4.docx
Normal file
BIN
Labs/Lab4/Lab4.pdf
Normal file
17
Labs/Lab4/Queries.txt
Normal file
@ -0,0 +1,17 @@
|
||||
Question 1:
|
||||
|
||||
select CUS_FNAME as `First Name`, CUS_LNAME as `Last Name`, CUS_INITIAL as `Customer Initial`
|
||||
from CUSTOMER
|
||||
where CUS_AREACODE = '615' and CUS_BALANCE != '0';
|
||||
|
||||
Question 2:
|
||||
|
||||
select P_DESCRIPT as `Product Description` , P_PRICE as `Price`
|
||||
from PRODUCT
|
||||
where P_QOH < 15;
|
||||
|
||||
Question 3:
|
||||
|
||||
select P_CODE as `Product Code`, P_DESCRIPT as `Product Description`, (P_PRICE * (1 - P_DISCOUNT)) as `Discounted Price`
|
||||
from PRODUCT
|
||||
where P_PRICE > 100;
|
BIN
Labs/Lab4/Queries.zip
Normal file
BIN
Labs/Lab4/SQL Lab4.zip
Normal file
9
Labs/Lab4/SQL Lab4/Q1 Output.txt
Normal file
@ -0,0 +1,9 @@
|
||||
+------------+-----------+------------------+
|
||||
| First Name | Last Name | Customer Initial |
|
||||
+------------+-----------+------------------+
|
||||
| Kathy | Smith | W |
|
||||
| Paul | Olowski | F |
|
||||
| James | Brown | G |
|
||||
| George | Williams | NULL |
|
||||
+------------+-----------+------------------+
|
||||
|
3
Labs/Lab4/SQL Lab4/Q1.sql
Normal file
@ -0,0 +1,3 @@
|
||||
select CUS_FNAME as `First Name`, CUS_LNAME as `Last Name`, CUS_INITIAL as `Customer Initial`
|
||||
from CUSTOMER
|
||||
where CUS_AREACODE = '615' and CUS_BALANCE != '0';
|
11
Labs/Lab4/SQL Lab4/Q2 Output.txt
Normal file
@ -0,0 +1,11 @@
|
||||
+----------------------------------+--------+
|
||||
| Product Description | Price |
|
||||
+----------------------------------+--------+
|
||||
| Power painter, 15 psi., 3-nozzle | 109.99 |
|
||||
| B&D jigsaw, 12-in. blade | 109.92 |
|
||||
| B&D jigsaw, 8-in. blade | 99.87 |
|
||||
| B&D cordless drill, 1/2-in. | 38.95 |
|
||||
| Sledge hammer, 12 lb. | 14.40 |
|
||||
| Hicut chain saw, 16 in. | 256.99 |
|
||||
+----------------------------------+--------+
|
||||
|
3
Labs/Lab4/SQL Lab4/Q2.sql
Normal file
@ -0,0 +1,3 @@
|
||||
select P_DESCRIPT as `Product Description` , P_PRICE as `Price`
|
||||
from PRODUCT
|
||||
where P_QOH < 15;
|
9
Labs/Lab4/SQL Lab4/Q3 Output.txt
Normal file
@ -0,0 +1,9 @@
|
||||
+--------------+-------------------------------------+------------------+
|
||||
| Product Code | Product Description | Discounted Price |
|
||||
+--------------+-------------------------------------+------------------+
|
||||
| 11QER/31 | Power painter, 15 psi., 3-nozzle | 109.9900 |
|
||||
| 2232/QTY | B&D jigsaw, 12-in. blade | 104.4240 |
|
||||
| 89-WRE-Q | Hicut chain saw, 16 in. | 244.1405 |
|
||||
| WR3/TT3 | Steel matting, 4'x8'x1/6", .5" mesh | 107.9550 |
|
||||
+--------------+-------------------------------------+------------------+
|
||||
|
3
Labs/Lab4/SQL Lab4/Q3.sql
Normal file
@ -0,0 +1,3 @@
|
||||
select P_CODE as `Product Code`, P_DESCRIPT as `Product Description`, (P_PRICE * (1 - P_DISCOUNT)) as `Discounted Price`
|
||||
from PRODUCT
|
||||
where P_PRICE > 100;
|
65
Labs/Lab5/AllQueries.txt
Normal file
@ -0,0 +1,65 @@
|
||||
1:
|
||||
select *
|
||||
from LGBRAND
|
||||
order by BRAND_TYPE;
|
||||
2:
|
||||
select BRAND_TYPE as `Brand Type` ,count(BRAND_TYPE) as `Number of each brand types`
|
||||
from LGBRAND
|
||||
group by BRAND_TYPE;
|
||||
3:
|
||||
select CUST_STATE as `State`, count(CUST_BALANCE) as `Number of non zero balances`
|
||||
from LGCUSTOMER
|
||||
where CUST_BALANCE != 0
|
||||
group by CUST_STATE;
|
||||
4:
|
||||
select CUST_STATE as `State`, count(CUST_BALANCE) as `Number of non zero balances`
|
||||
from LGCUSTOMER
|
||||
where
|
||||
CUST_BALANCE != 0
|
||||
group by CUST_STATE
|
||||
having
|
||||
count(CUST_CODE) > 100;
|
||||
5:
|
||||
select CUST_STATE as `State`, count(CUST_BALANCE) as `Number of non zero balances`
|
||||
from LGCUSTOMER
|
||||
where
|
||||
CUST_BALANCE != 0
|
||||
group by CUST_STATE
|
||||
having
|
||||
count(CUST_CODE) > 100
|
||||
order by STATE desc;
|
||||
6:
|
||||
select CUST_STATE as `State`, count(CUST_BALANCE) as `Number of non zero balances`
|
||||
from LGCUSTOMER
|
||||
where
|
||||
CUST_BALANCE != 0
|
||||
group by CUST_STATE
|
||||
having
|
||||
count(CUST_CODE) > 100
|
||||
order by count(CUST_CODE);
|
||||
7:
|
||||
select SUM(LINE_NUM) as `Number of Products purchased`, BRAND_TYPE as `Brand`
|
||||
from LGCUSTOMER
|
||||
natural join LGINVOICE
|
||||
natural join LGLINE
|
||||
natural join LGPRODUCT
|
||||
natural join LGBRAND
|
||||
where
|
||||
CUST_STATE = "ME"
|
||||
group by BRAND_TYPE;
|
||||
8:
|
||||
select SUM(LINE_NUM) as `Number of Products purchased`, BRAND_TYPE as `Brand`, CUST_STATE as `State`
|
||||
from LGCUSTOMER
|
||||
natural join LGINVOICE
|
||||
natural join LGLINE
|
||||
natural join LGPRODUCT
|
||||
natural join LGBRAND
|
||||
group by BRAND_TYPE, CUST_STATE
|
||||
having SUM(LINE_NUM) < 10;
|
||||
9:
|
||||
select
|
||||
MAX(EMP_HIREDATE) as `Hire date`,
|
||||
EMP_FNAME as `First Name`,
|
||||
EMP_LNAME as `Last Name`,
|
||||
DATEDIFF(CURRENT_DATE, MAX(EMP_HIREDATE)) as `Days since hire`
|
||||
from LGEMPLOYEE;
|
BIN
Labs/Lab5/IsaacShoebottom_CS1103_Lab5.docx
Normal file
BIN
Labs/Lab5/IsaacShoebottom_CS1103_Lab5.pdf
Normal file
BIN
Labs/Lab5/IsaacShoebottom_CS1103_Lab5.zip
Normal file
BIN
Labs/Lab5/Lab5 - Complex Queries.pdf
Normal file
BIN
Labs/Lab5/Lab5.zip
Normal file
3
Labs/Lab5/Q1.sql
Normal file
@ -0,0 +1,3 @@
|
||||
select *
|
||||
from LGBRAND
|
||||
order by BRAND_TYPE;
|
17
Labs/Lab5/Q1.txt
Normal file
@ -0,0 +1,17 @@
|
||||
+----------+--------------------+------------+
|
||||
| BRAND_ID | BRAND_NAME | BRAND_TYPE |
|
||||
+----------+--------------------+------------+
|
||||
| 25 | STUTTENFURST | CONTRACTOR |
|
||||
| 27 | HOME COMFORT | CONTRACTOR |
|
||||
| 28 | OLDE TYME QUALITY | CONTRACTOR |
|
||||
| 30 | LONG HAUL | CONTRACTOR |
|
||||
| 35 | LE MODE | PREMIUM |
|
||||
| 26 | HOMESTEADER FINEST | PREMIUM |
|
||||
| 33 | BINDER PRIME | PREMIUM |
|
||||
| 34 | PRIME OF LIFE | VALUE |
|
||||
| 32 | YOUR HOME HELPER | VALUE |
|
||||
| 31 | VALU-MATTE | VALUE |
|
||||
| 29 | BUSTERS | VALUE |
|
||||
| 24 | REGAL HOME | VALUE |
|
||||
| 23 | FORESTERS BEST | VALUE |
|
||||
+----------+--------------------+------------+
|
3
Labs/Lab5/Q2.sql
Normal file
@ -0,0 +1,3 @@
|
||||
select BRAND_TYPE as `Brand Type` ,count(BRAND_TYPE) as `Number of each brand types`
|
||||
from LGBRAND
|
||||
group by BRAND_TYPE;
|
7
Labs/Lab5/Q2.txt
Normal file
@ -0,0 +1,7 @@
|
||||
+------------+----------------------------+
|
||||
| Brand Type | Number of each brand types |
|
||||
+------------+----------------------------+
|
||||
| CONTRACTOR | 4 |
|
||||
| PREMIUM | 3 |
|
||||
| VALUE | 6 |
|
||||
+------------+----------------------------+
|
4
Labs/Lab5/Q3.sql
Normal file
@ -0,0 +1,4 @@
|
||||
select CUST_STATE as `State`, count(CUST_BALANCE) as `Number of non zero balances`
|
||||
from LGCUSTOMER
|
||||
where CUST_BALANCE != 0
|
||||
group by CUST_STATE;
|
28
Labs/Lab5/Q3.txt
Normal file
@ -0,0 +1,28 @@
|
||||
+-------+-----------------------------+
|
||||
| State | Number of non zero balances |
|
||||
+-------+-----------------------------+
|
||||
| AL | 39 |
|
||||
| CT | 12 |
|
||||
| DE | 2 |
|
||||
| FL | 57 |
|
||||
| GA | 32 |
|
||||
| IN | 52 |
|
||||
| KY | 42 |
|
||||
| MA | 34 |
|
||||
| MD | 51 |
|
||||
| ME | 14 |
|
||||
| MI | 30 |
|
||||
| MS | 24 |
|
||||
| NC | 59 |
|
||||
| NH | 8 |
|
||||
| NJ | 34 |
|
||||
| NY | 104 |
|
||||
| OH | 60 |
|
||||
| PA | 118 |
|
||||
| RI | 8 |
|
||||
| SC | 23 |
|
||||
| TN | 32 |
|
||||
| VA | 38 |
|
||||
| VT | 27 |
|
||||
| WV | 27 |
|
||||
+-------+-----------------------------+
|
7
Labs/Lab5/Q4.sql
Normal file
@ -0,0 +1,7 @@
|
||||
select CUST_STATE as `State`, count(CUST_BALANCE) as `Number of non zero balances`
|
||||
from LGCUSTOMER
|
||||
where
|
||||
CUST_BALANCE != 0
|
||||
group by CUST_STATE
|
||||
having
|
||||
count(CUST_CODE) > 100;
|
6
Labs/Lab5/Q4.txt
Normal file
@ -0,0 +1,6 @@
|
||||
+-------+-----------------------------+
|
||||
| State | Number of non zero balances |
|
||||
+-------+-----------------------------+
|
||||
| NY | 104 |
|
||||
| PA | 118 |
|
||||
+-------+-----------------------------+
|
8
Labs/Lab5/Q5.sql
Normal file
@ -0,0 +1,8 @@
|
||||
select CUST_STATE as `State`, count(CUST_BALANCE) as `Number of non zero balances`
|
||||
from LGCUSTOMER
|
||||
where
|
||||
CUST_BALANCE != 0
|
||||
group by CUST_STATE
|
||||
having
|
||||
count(CUST_CODE) > 100
|
||||
order by STATE desc;
|
7
Labs/Lab5/Q5.txt
Normal file
@ -0,0 +1,7 @@
|
||||
+-------+-----------------------------+
|
||||
| State | Number of non zero balances |
|
||||
+-------+-----------------------------+
|
||||
| PA | 118 |
|
||||
| NY | 104 |
|
||||
+-------+-----------------------------+
|
||||
|
8
Labs/Lab5/Q6.sql
Normal file
@ -0,0 +1,8 @@
|
||||
select CUST_STATE as `State`, count(CUST_BALANCE) as `Number of non zero balances`
|
||||
from LGCUSTOMER
|
||||
where
|
||||
CUST_BALANCE != 0
|
||||
group by CUST_STATE
|
||||
having
|
||||
count(CUST_CODE) > 100
|
||||
order by count(CUST_CODE);
|
7
Labs/Lab5/Q6.txt
Normal file
@ -0,0 +1,7 @@
|
||||
+-------+-----------------------------+
|
||||
| State | Number of non zero balances |
|
||||
+-------+-----------------------------+
|
||||
| NY | 104 |
|
||||
| PA | 118 |
|
||||
+-------+-----------------------------+
|
||||
|
9
Labs/Lab5/Q7.sql
Normal file
@ -0,0 +1,9 @@
|
||||
select SUM(LINE_NUM) as `Number of Products purchased`, BRAND_TYPE as `Brand`
|
||||
from LGCUSTOMER
|
||||
natural join LGINVOICE
|
||||
natural join LGLINE
|
||||
natural join LGPRODUCT
|
||||
natural join LGBRAND
|
||||
where
|
||||
CUST_STATE = "ME"
|
||||
group by BRAND_TYPE;
|
8
Labs/Lab5/Q7.txt
Normal file
@ -0,0 +1,8 @@
|
||||
+------------------------------+------------+
|
||||
| Number of Products purchased | Brand |
|
||||
+------------------------------+------------+
|
||||
| 249 | CONTRACTOR |
|
||||
| 126 | PREMIUM |
|
||||
| 130 | VALUE |
|
||||
+------------------------------+------------+
|
||||
|
8
Labs/Lab5/Q8.sql
Normal file
@ -0,0 +1,8 @@
|
||||
select SUM(LINE_NUM) as `Number of Products purchased`, BRAND_TYPE as `Brand`, CUST_STATE as `State`
|
||||
from LGCUSTOMER
|
||||
natural join LGINVOICE
|
||||
natural join LGLINE
|
||||
natural join LGPRODUCT
|
||||
natural join LGBRAND
|
||||
group by BRAND_TYPE, CUST_STATE
|
||||
having SUM(LINE_NUM) < 10;
|
6
Labs/Lab5/Q8.txt
Normal file
@ -0,0 +1,6 @@
|
||||
+------------------------------+-------+-------+
|
||||
| Number of Products purchased | Brand | State |
|
||||
+------------------------------+-------+-------+
|
||||
| 7 | VALUE | DE |
|
||||
+------------------------------+-------+-------+
|
||||
|