Skip to content

Instantly share code, notes, and snippets.

Schema management; how do you manage "n" database schemas being managed?
Production Example
------------------
UPDATE project_affiliation pa
SET hasCommented = 1
WHERE ISNULL(pa.endedAt)
AND hasCommented <> 1
AND EXISTS (
SELECT 1