summaryrefslogtreecommitdiff
path: root/migrations/2024-12-13T21-55-38_github_support/down.sql
diff options
context:
space:
mode:
Diffstat (limited to 'migrations/2024-12-13T21-55-38_github_support/down.sql')
-rw-r--r--migrations/2024-12-13T21-55-38_github_support/down.sql6
1 files changed, 6 insertions, 0 deletions
diff --git a/migrations/2024-12-13T21-55-38_github_support/down.sql b/migrations/2024-12-13T21-55-38_github_support/down.sql
new file mode 100644
index 0000000..dd5c51e
--- /dev/null
+++ b/migrations/2024-12-13T21-55-38_github_support/down.sql
@@ -0,0 +1,6 @@
+-- Your SQL goes here
+ALTER TABLE "events" DROP CONSTRAINT check_event_type;
+ALTER TABLE "events" ADD CONSTRAINT check_event_type CHECK (
+ ("target_alias_id" IS NOT NULL AND "event_type" < 99)
+ OR ("custom_alias_id" IS NOT NULL AND "event_type" >= 99)
+); \ No newline at end of file