Project Part #4
Performance analysis (bulk load, indexes, and views)
1. [10] Generate data set which contains at least 2,000 tuples (no more than 5,000) in a table you choose. Use your favorite language to generate a text file (example format: fields delimited by comma, tuples delimited by new line). Submit the source code for data generation. Show the first 10 lines, 10 lines in some middle position, and last 10 lines of the text file.
2. [15] Load into the table with the newly generated text file using the facility of underlying database system. You may want to delete all records before loading. Before and after loading, show the result of query "select count(*) from TABLE".
3. [10] Create an index for a field. Run a query containing a condition of that field. Compare the running times of the query with and without using the index. Submit the scripts and running times. Explain why. Lastly drop the index.
4. [15] Create a view. Run another query with and without using the view. Try to update the view and see what happens. Explain why. Lastly, drop the view.