Session Ready
Exercise

User-defined data types

ENUM or enumerated data types are great options to use in your database when you have a column where you want to store a fixed list of values that rarely change. Examples of when it would be appropriate to use an ENUM include days of the week and states or provinces in a country.

Another example can be the directions on a compass (i.e., north, south, east and west.) In this exercise, you are going to create a new ENUM data type called compass_position.

Instructions 1/2
undefined XP
  • 1
  • 2
  • Create a new enumerated data type called compass_position.
  • Use the four positions of a compass as the values.