Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Quiz

Instruction

Very well done! Let's get back to something more challenging.

Exercise

A small healthcare unit wants to have a table with treatment options. The treatment offers are based on the International Statistical Classification of Diseases and Related Health Problems.

Create a table called treatment with the following columns:

  • name - a text of up to 100 characters,
  • disease_chapter - a text of up to 4 characters,
  • disease_block - a three-letter code,
  • price - a decimal number with up to 6 digits, two of which are after the decimal point.
The columns: name, disease_chapter, disease_block form the primary key. If no price is provided, the default value should be 0.00.

Stuck? Here's a hint!

We discussed constraints in Part 5. Take a look back to refresh your memory.