Consider a relation with schema R(A,B,C,D) and an unknown set of functional dependencies. For each closed attribute set below, give a set of functional dependencies that is consistent with it.
He inserted his data into the database, then he realized that there is something wrong with it: it was difficult to update. He hires you as a consultant to fix his data management problems. He hands you his data in the file hw1_data.txt, located in the .tar archive, and tells you, "Fix it for me!". Help him by normalizing his database. Unfortunately you cannot sit down with Mr. Frumble and iscuss his application to find out the functional dependencies, as you should normally do, because Mr. Frumble is simply too busy. So you have to reverse engineer the functional dependencies from his data instance. You should do the following steps:
> psql -f "postgres_import.sql" your_databaseThis will create a table called hw1_data.
For this point you should turn in all functional dependencies that you found, and for each of them the SQL query that discovered it, together with the answer of the query.
For this point turn in the SQL commands for creating the tables.
Here, turn in the SQL queries that load the tables, and the tables' contents after loading them (obtained by running SELECT * FROM Table).