Constraints

8 Foreign Key Constraints

Constraint Name Child Column Parent Column Delete Rule
quality_scores_job_id_fkey
quality_scores.job_id
pipeline_jobs.id
Restrict delete
quality_scores_draft_id_fkey
quality_scores.draft_id
drafts.id
Restrict delete
published_posts_draft_id_fkey
published_posts.draft_id
drafts.id
Restrict delete
published_posts_job_id_fkey
published_posts.job_id
pipeline_jobs.id
Restrict delete
serp_analyses_job_id_fkey
serp_analyses.job_id
pipeline_jobs.id
Restrict delete
editorial_briefs_job_id_fkey
editorial_briefs.job_id
pipeline_jobs.id
Restrict delete
drafts_job_id_fkey
drafts.job_id
pipeline_jobs.id
Restrict delete
keywords_post_id_fkey
keywords.post_id
published_posts.id
Restrict delete

Check Constraints

Table Constraint Name Constraint
news_packs news_packs_source_mode_check (source_mode = ANY (ARRAY['serp'::text, 'internal'::text, 'manual'::text]))
pipeline_jobs pipeline_jobs_current_step_check (current_step = ANY (ARRAY['keyword_submitted'::text, 'serp_researched'::text, 'content_extracted'::text, 'brief_created'::text, 'draft_generated'::text, 'quality_scored'::text, 'revision_complete'::text, 'published'::text, 'failed'::text]))