Instruction
Good! Again, we failed to add the new row. The database won't let us add a NULL value as the primary key.
So, to sum up what we've learned so far:
- the primary key always must have a value, it can't be a
NULL, - there can only be one row with a given primary key value.
In the next parts of the course, you will find out that we use the primary key to refer to the table from other tables.
It is worth noting that when we create a primary key, an index is also created. It is a data structure which facilitates data selection and sorting in the table. Indexes are outside the scope of this course, but they are an important part of database design.
Exercise
Click the button to continue.



