-- 155_analyze_events_policy_violation_idx.sql
-- PR-A: policy_violation=true 행 추출 인덱스 (migration 153 분할).
-- under_escalation 재처리 큐 + 야간 sweep 감사용 partial index.

CREATE INDEX IF NOT EXISTS idx_analyze_events_policy_violation
    ON analyze_events (created_at)
    WHERE policy_violation = true;
