-- Migration: Add 'registered' status to videos status check constraint
-- Date: 2026-05-15
-- Usage: psql -U accusys -d momentry -f migrate_add_registered_status.sql

ALTER TABLE videos DROP CONSTRAINT IF EXISTS chk_videos_status;
ALTER TABLE videos ADD CONSTRAINT chk_videos_status
  CHECK (status::text = ANY (ARRAY['registered'::text, 'pending'::text, 'processing'::text, 'completed'::text, 'failed'::text]));
