Created
October 25, 2021 23:27
-
-
Save beargiles/0d315e93f895665fb83d82c8cd787f28 to your computer and use it in GitHub Desktop.
PostgreSQL table with check constraint
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE color ( | |
color TEXT CHECK (color IN ('RED', 'GREEN', 'BLUE')) | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment