Loading topic
ORDER BY, WHERE,8 min readrefunded order status, and a team decides cancelled should be spelled canceled. This chapter covers the two ALTER TYPE commands that handle these changes without rewriting your tables: ADD VALUE and `RENAME VALU9 min readALTER TYPE ... ADD VALUE. You should also know basic psql usage and that PostgreSQL has system catalogs such8 min readNOT NULL setting, and CHECK constraints. You define the rules once, and every column, function parameter, or variable of that type follows them.6 min readCREATE TABLE, INSERT, SELECT, and WHERE. You should also know what CHECK and NOT NULL constraints do on a table, and that SQL uses three-valued logic: a condition can be true, false, or unknown. The previous chapter showed how to create a domain. This o8 min readCHECK, NOT NULL, and DEFAULT, and that you know a CHECK that evaluates to NULL passes. It also assumes you can run SQL in psql or a similar client. Everything runs in a scratch schema, so you can clean up at the end.8 min readCREATE TABLE, INSERT, SELECT, and WHERE. It also assumes you know CHECK and NOT NULL constraints and basic foreign keys. It builds on the earlier chapters of this tutorial: enum ordering and ALTER TYPE, the type-replacement workaround for removing values, 8 min read