1. Learn
  2. /
  3. Courses
  4. /
  5. Creating PostgreSQL Databases

Exercise

Choosing data types at table creation

It is best to specify the data type for a column when the table is initially created. The type can be changed later. However, this change may have unintended consequences if the column contains previously populated values. In this exercise, you will specify data types based on the category of data to which the values belong.

We will now return to the Small Business Association (SBA) database example from Chapter 1. SBA loans are provided for specific business projects. You will complete the definition of the project table using the most appropriate column type.

Instructions

100 XP
  • Complete the CREATE TABLE command for the project table using the correct data type from the following choices: TEXT, BOOLEAN, and NUMERIC.