Skip to main content

care-sql-code-review

Review raw SQL for the CARE analytics repo (care_analytics_sql) — hand-written Postgres queries that power Metabase dashboards and run directly against the CARE database's physical tables (emr_*, users_user). Use this whenever reviewing, writing, or debugging an analytics SQL query or its diff: new report queries, changes to existing ones, reported wrong numbers, or slow dashboards. It checks correctness (status-based record validity — excluding entered_in_error and terminal statuses — join fan-out inflating money totals, tenant/facility scoping, NULL handling), performance (sargability, unindexed JSONB/array access), and maintainability (hardcoded magic IDs, parameter docs). CARE-specific: it knows the emr_* schema, which columns are indexed, and the traps created because raw SQL bypasses the Django ORM's automatic filtering — including that clinical records are invalidated by status (entered_in_error), not by the deleted flag. Prefer this over the generic sql-code-review skill for anything under care_analyt

Zur Installation springen

Quellinformationen

Repository
ohcnetwork/skills
Letzte Quellaktivität
3. Juli 2026 um 10:35
Erkannte Sprache von SKILL.md
Englisch
Sterne
0
Forks
0

Installationsoptionen

Standardmäßig ist der Prompt ausgewählt, der zuerst die Quelle prüft. Sie können zu einem direkten Befehl wechseln oder eine lokale Kopie herunterladen.

Quelldateien prüfen

Lesen Sie SKILL.md und alle von SkillsMP angezeigten Begleitdateien, bevor Sie sich für eine Installation entscheiden.