SQL Exercises/Pieces and providers

Exercises
1. Select the name of all the pieces.

2. Select all the providers' data.

3. Obtain the average price of each piece (show only the piece code and the average price).

4. Obtain the names of all providers who supply piece 1.

5. Select the name of pieces provided by provider with code "HAL".

6. For each piece, find the most expensive offering of that piece and include the piece name, provider name, and price (note that there could be two providers who supply the same piece at the most expensive price).

7. Add an entry to the database to indicate that "Skellington Supplies" (code "TNBC") will provide sprockets (code "1") for 7 cents each.

8. Increase all prices by one cent.

9. Update the database to reflect that "Susan Calvin Corp." (code "RBT") will not supply bolts (code 4).

10. Update the database to reflect that "Susan Calvin Corp." (code "RBT") will not supply any pieces (the provider should still remain in the database).