Skip to content
Snippets Groups Projects
Commit 734f1473 authored by Nikita Korzhitskii's avatar Nikita Korzhitskii :bulb:
Browse files

Remove old files

parent 3e8976a0
No related branches found
No related tags found
No related merge requests found
# Lab 1
Name the file lab1.sql
## Getting started
see: https://www.ida.liu.se/~TDDD37/labs/mysqllabs/index.en.shtml
## The lab report
* See the example **lab1.sql** file for the report structure
* The questions should be answered in chronological order.
r
* The file should be able to run using `SOURCE lab1.sql;` in MySQL without error.
* All created tables and views should be deleted in the beginning of the file.
* The written questions should be within SQL-comments.
"/* like this */ "
\ No newline at end of file
/*
Lab 1 report <Student_names and liu_id>
*/
/* All non code should be within SQL-comments like this */
/*
Drop all user created tables that have been created when solving the lab
*/
DROP TABLE IF EXISTS custom_table CASCADE;
/* Have the source scripts in the file so it is easy to recreate!*/
SOURCE company_schema.sql;
SOURCE company_data.sql;
/*
Question 1: Print a message that says "hello world"
*/
SELECT 'hello world!' AS 'message';
/* Show the output for every question.
+--------------+
| message |
+--------------+
| hello world! |
+--------------+
1 row in set (0.00 sec)
*/
# The lab report
The report should contain the following three files:
* An PDF file with a picture of the EER diagram (task 1).
* A text file (or a PDF file) with notes regarding the additional choices and
assumptions you have made when creating your EER diagram.
* An PDF file with a picture of the diagram that presents your relational
database schema (task 2).
Place these three file into the gitlab folder.
## EER-diagram
If you want to use some software for drawing diagrams, notice that this folder contains an **XML file** of the EER-diagram used as an simple example for this lab assignment. Download this file and upload it to [draw.io](https://www.draw.io).
Next, make your changes in draw.io and when you are finished, export the diagram as a pdf file which you add it to your lab report.
If downloading it doesn't work to the following:
1. go to draw.io website, press create new diagram
2. draw your ER diagram using the shapes in the drop-down menu 'Entity relation'
3. name the file ER.xml and save it where you want
## Text file
If you make choices and add constraints for aspects that are not explicitly specified in the given data
requirements, clearly write down the choices and assumptions that you make.
## Relational Model (RM)
In addition to the XML file with the EER-diagram, this folder contains another XML file with an example diagram that represents the relational schema.
You will have to complete the relations by yourselves. Use draw.io as before and export the final diagram as pdf file for your lab report.
<mxfile host="www.draw.io" modified="2020-01-23T11:01:53.580Z" agent="Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.117 Safari/537.36" etag="b1kfseghPWKRh943A4ro" version="12.5.6" type="device"><diagram id="ef44bf90-a080-4c4b-d77c-b11ea831b01f" name="Page-1">5VdNm9IwEP41Pa4P/eLB48LietCLHHSP2XZo46aZmqZQ/PUmdEJbKIqK7j7KATLvTJLp+84kxQsXRXOvWJm/xxSEF0zSxgvvvCB4HU3NtwV2LRBHQQtkiqct5HfAin8FAieE1jyFahCoEYXm5RBMUEpI9ABjSuF2GLZGMdy1ZBmcAKuEiVP0I0913qKzeNLhb4FnudvZn5DnkSVPmcJa0n5eEK73n9ZdMLcWxVc5S3Hbg8KlFy4Uom5HRbMAYal1tLXz3pzxHvJWIPUlE0iWDRM1uIynwkydVyWTNkG9I1KmX2qb1Xybcw03xp0Y/NaESFQFE12AGWX0u1+pdsCt1oo/1hqcx+RVH0cbrN3awcEgi2BPLtj0Jy6ZVZvL3dbUosFyXQhj+YfZfTqIoQ0oDU0PInruAQvQamdCnNdJRaUcTcnedoXhu7rNe0UREsaoFrPD0p0eZkCSjMsT/UF5xtR4UcwfGHwO5v3w5PkhNWcEmah0jhlKJpYdOh8y1GMDGq4/WfhVTNYDBRl61K7nsuYDzfoMWu/ocGS1RgN1+75DLH/EdYW1Sij7mI5RpjJwUdT99sG+K4gCwTTfDA/H32E3/p/rOoyesa5nP8/8GqW+qfZlaHn3p2VzynpbIihXSQ4FM2Efgkv5N7TpIcmVVvgECxSoDCJR2uZacyGOICZ4Jo2ZGDHA4HMrAjfX+C05Cp6m+84cU3Wo+xWEncVDXcMRXaP4VNfgGufV+Zv80vv3hV20hzb5K8f9+ZvWlv81+8Lvsd+u/c/3xZGw/lhfjAj7C31hzO7lee/r/UEJl98A</diagram></mxfile>
\ No newline at end of file
<mxfile host="www.draw.io" modified="2020-01-23T11:00:49.638Z" agent="Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.117 Safari/537.36" version="12.5.6" etag="_6t7q4lIZEtHZujkMUFi" type="device"><diagram id="9e350d63-8be0-d780-5e5e-1543171d6a96" name="Page-1">7Vtbc5s4FP41fowHIS7mMU7SdGeabjbZTtunDjay0QQjF+TY7q9fCXGVwCYO+JLZzNQ1RyDh75zznYtgAG8Wm/vIXfoPxEPBQNe8zQDeDnTdMSz2yQVbITANXQjmEfaECBSCZ/wHpUItla6wh+LKiZSQgOJlVTglYYimtCJzo4isq6fNSFBddenOkSJ4nrqBKv2OPeoL6cjUCvlnhOd+tjLQ0pGJO32ZR2QVpusNdDhL/sTwws3mSs+Pfdcj65II3g3gTUQIFd8WmxsUcGgz2MR1nxpG8/uOUEhbXQBMccmrG6xQds9WwC4eT9iXOf/yCYtrQo64G3k4dANMMVMQ+8Fbvl7gTnE45+BzTaEN5SMBmb5wEcNC1wJ3ggJxDuaj7E5v2H9f2T8SsY+HbFV2r/nCKUZ0m+klmRqOfboImACwrzGNyAu6IQGbBd6GJGRnjmfshiURu+N5yA6nDBjE5ONXFFHMNH6dDiyw5/FlxmsfU/S8dKd8zTUzbyZLNIo4ZhpfM1MaP/Dc2E9G+N3MSEhTawZW/gPK6kg1xFdHm5IoVc89IgtEIw5qOmpZqamkrmSB1JXWhWEamfn5JaPMjNVNfWGeT13YA/uSmkSTeVg15iEphcGx5F8j9HuFI+T9xRGeJfiVNZUB/oVbwiOJmQURDvyEUEoWMqwykhGhbnqBo3WDrKNXkTUz9ikhC2qA1TsB1t4PLAq9a05mhRU3Gj7jGS35e4sRIq/CgipQJSDMHRYWoYDp5rXKnXXopCs8EhzSsh7Mqh4cCeCYrKIpSq8qk9m+iTRpIupGc0SViRJl5T+7pf5GjbzJ8a8o0vq9ItnAVZxo5ppToLHcFIMZ532LEedQH3N2jbeLCeHr8nmSqdwF56OUHbW1j8IkipC14NZ4NZ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J6LLpyeOZ08n70OY5hCaJoSOxoKmbhtSpeoYQ2DoAJqWDm2oOQf2JoGjVwMGBEe2NrVLcafa2yVu9QBN8uQ8tywFC6smVsD+YoXacXhSsP4omzuOVBwawBrq6oNpTp0GbLlB350OssqkbPAfYzd5ZJ6bvY96aviUQ9KeB/ry8Jd30duFv06DWesHAUdavYbfGczkfVbr0PJc3j5XJuo7XGUPTHT+xsq/hLqBUDDFU7wU72npGpmxDx4RxZuDT4e/jtL+NRN5U2DJ4UwANscD85bPtaIkThmpo8LKrG6/GTVUDeq4+oAXydhh8XKoMI3iBVx49x8=</diagram></mxfile>
\ No newline at end of file
# Lab 3
## Handing in
Submit the lab report as a pdf or a txt file. Make sure that the document mentions your LiU IDs.
\ No newline at end of file
# Lab 4
Lab 4 is a big project that contains different parts.
## Part 1
For the first part the following should be handed in:
* EER-diagram as a pdf file
* Relational Model as a pdf file
* Functional dependencies for all relations as .txt or .pdf
**Please mark your courseCode_GroupNumber, name, and liU-id on the file (the GroupNumber can be found on Webreg, where you registered the lab)**
e.g.,<br/>
TDDD37_GroupA1:<br/>
YOURNAME (liU-id)<br/>
XXXXXXXX (liU-id)
### EER-diagram and Relational Model
Same as in lab 2, do it in draw.io and add it to gitlab
### Functional depdencies
Find the Candidate keys, primary keys and whether the table is in BCNF or not. If it is not in BCNF, motivate why!
## Part 2
This is the coding phase of the project. **Do not start coding until your EER and RM is approved!**
When you make sure that all test scripts could output expected result on your project, the following should be handed in:
* EER-diagram as .pdf
* Relational Model as .pdf
* Functional dependencies for all relations as .txt or .pdf
* Project code as one file named lab4.sql, which should be executable directly without any error
* Answers to the non code questions as SQL-comments in the lab4.sql file, place them at the end of the file
* An identified secondary index as SQL-comments in the lab4.sql file (do not implement it), place at the end of the file
* A file named q10b.sql that is your modified version of Question10MakeBooking.sql
### Code
Please delete all your created tables and views in the beginning of the file!
You can do this by temporarily disabling Foreign Keys in MySQL. Do not forget to enable it again!
`
SET FOREIGN_KEY_CHECKS=0;
DROP TABLE XXX;
SET FOREIGN_KEY_CHECKS=1;`
#### The test scripts
**Question 3**
Confirm that you have 208 flights in your database
**Question 6**
Confirm that the output is correct.
Confirm that the change has actually been done in the database. i.e. in Test 13, confirm that the reservation was actually delete.
**Question 7**
This test is correct if there is no output at all. If you get output it means something is wrong. See which rows are different to the result.
Common errors are rounding errors and route errors
#### Issues
You will most likely run into problems during the coding phase! Create issues, tag your lab assistant and reference where in the code you are having problems!
## Part 3
Send in the code to urkund. Change the file ending from lab4.sql to lab4.txt! Send it to urkund when you have passed lab4c) on WebReg! Details are on course website.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment