Imitate the examples that you have seen this week.

Choose a theme for a database. This might be a shopping list, sports statistics, destinations for a fantasy vacation, a membership list for an organization, and so on. Collect the information that you will include in your database.

Write a SQL script that...

  • Includes your name, an identification of the exercise, and the date in a comment at the top of the script.
  • Creates a database.
  • Creates a single table within that database. Create a table that contains 4 or more columns. Create a table that contains a variety of types of data (for example, VARCHAR, INTEGER, DATE, and so on).
  • Inserts 12 or more records into this database.
  • Queries the database with 6 or more SELECT statements. Use several of the different options that you have seen (for example, OR, AND, NOT, LIKE, IN, IS NULL, <, =, and so on).
  • Precede each SELECT statement with a comment that describes what you are trying to accomplish with that query.

Last modified: Thursday, October 21, 2021, 9:40 AM