Assignment #2
(total = 100 pts., due on February 3, Thursday)

Please turn in the homework electronically here. Make sure there is only one file in the submission (i.e., zip everything). Also, please use .PDF format for the homework. Other writable formats such as Words are not accepted.

1. (10 pts) Your database has been created and can be acessed with phpAdmin, a Web-based database administration tool. phpMyAdmin can be activated at From the "Server Choice", select "". Perform the following tasks:

  1. Copy the data and program files from`
  2. Modify the three PHP scripts (insert_dept.php, insert_emp.php, insert_works.php) so it points to your own database and uses your ID and password. Run these scripts and check whether the tables are created and data are populated. Here is some tip on how to run PHP scripts on your account:
  3. Use MySQL functions to export the data from tables dept, emp, and works into either fixed length or comma delimited ASCII file format.
  4. Create a Microsoft Access database. Use the import function of Access to move data from the ASCII files into the Access database you have created.
  5. Submit the Access database as part of the homework.

2. Questions on normalizations:

  1. (15 pts) Exercise 15.19 on Page 537 in Elmasri and Navathe.
  2. (15 pts) Prove or disprove the following statements:
    -- {W->Z, X->Z} => {WX->Y}
    -- {X->Y, X->W, WY->Z} => {X->Z}
    -- {XY->Z, Y->W} => {XW->Z}
    -- {X->Z, Y->Z} => {X->Y}
    -- {X->Y, XY->Z} => {X->Z}
    -- {X->Y, Z->W} => {XZ->YW}
    -- {XY->Z, Z->W} => {Z->Y}
    -- {X->Y, Y->Z} => {X->YZ}
    -- {XY->Z, Z->W} => {X->W}
  3. (15 pts) Exercise 15.25 on Page 538 in Elmasri and Navathe.
  4. (15 pts) Exercise 15.26 on Page 539 in Elmasri and Navathe.
  5. (15 pts) Exercise 15.27 on Page 539 in Elmasri and Navathe.
  6. (15 pts) Exercise 15.30 on Page 540 in Elmasri and Navathe.