Database Systems - Homework Info PageHW1 HW2 HW3 Note: there is also a software page available. Homework 1For questions 10 and 11 you'll need to load extra rows in to the Course and Employee tables. The data to load can be found at the following two files:course_extra_data.txt employee_extra_data.txt The files are tabbed dilimited. MySQL supports this format as a default. If you are using a different database server you might need to specify that a tab is used as a delimiter, while importing the data. To import the files use the " LOAD DATA" command. Documentation for this command can be found
here. For example to load the extra course
data you would connect with the mysql client to the database you are using and then run the following command:load data local infile 'employee_extra_data.txt' into table Employee;Note: the example above uses the "local" keyword, which indicates to the client to search for the file localy relativly to where the client is executed. For the example above you would need to have the file employee_extra_data.txt placed in the current working directory from which the client was executed. Data types: When creating the tables all string data types can be defined as varchar(50). The "Salary" and "Grade" fields can be defined as int. Solution: sql queries, relational algebra Homework 2For question 7: the file hispo.xml is part of the Galax distribution. See the software page for instructions on installing Galax. If you don't want to use Galax you can get the file here.Note: the answer should include both the query and the result. The result should display both the partNum and its associated total sales. Solution: hw2_solution.txt Homework 3Question 1:All files provided are in the format of:operation dataOne operation per line. Where operation is one of either i for insert or d for delete and data is a consecutive string.
For example:
i 3nwCQP59l3KyhDC8nKkPNote: the data (the second parameter supplied) is to be used as the key for delete operations and for insert operations as both the key and value. The data to load file contains only insert operation. It is available at zip format here or tar.gz format here. There are two operations files: operations1_data.txt and operations2_data.txt. Guidelines:
Question 2:The data files, in mysql tab delimited format, are available here:course_hw3.txt employee_hw3.txt If you find that the above data set is too small (you don't get a significant difference between with and without indexes) you may use the following dataset which is larger. hw3_large_data.zip (100,000 lines in Employee table) Or you may choose to use the following data set which is huge: hw3_huge_data.zip (1,000,000 lines in Employee table) Note: the question requests: "Show the script ...". This means you need to show all sql statements you execute and their results. Question 3:Use the same file employee_hw3.txt from question 2. If you don't see a significant difference you may choose to use either the large or huge data set from question 2.Question 4:To generate the data use a scale factor of 0.02. No need to specify any other parameters. Thus, to generate the data use the following command:dbgen -s 0.02You can also get the table data here: tpch_table_data.zip. The data is separated using the "|" character. Thus to load the data in mysql you should use a command similar to: LOAD DATA LOCAL INFILE 'supplier.tbl' INTO TABLE tpch.SUPPLIER FIELDS TERMINATED BY '|';Solution: hw3_solution.txt |