Tickets with a restricted status

Tickets with a restricted status

A support service stores user requests in the tickets table. Create the table with the following columns: - id — an integer primary key; - status — a required text field of type TEXT. The status column must allow only the following values: - open; - closed; - pending. Add a database-level constraint that prevents any other status from being stored.

Just CREATE/ALTER/DROP — no trailing SELECT needed.

PostgreSQLv16

Your query result will appear here

No starting schema

This task starts with no tables — you'll create them via CREATE TABLE.

Focus radio
Paused · SomaFM · Fluid