From 7a9e229d5f4913d1a48c92615bcb3234f5dcfd33 Mon Sep 17 00:00:00 2001
From: Benedikt Peetz <benedikt.peetz@b-peetz.de>
Date: Thu, 11 Jun 2026 01:05:07 +0200
Subject: chore: Restore db migrations

---
 .../turtle/db/server-pg-migrations/20230315224203_create-deleted.sql | 5 +++++
 1 file changed, 5 insertions(+)
 create mode 100644 crates/turtle/db/server-pg-migrations/20230315224203_create-deleted.sql

(limited to 'crates/turtle/db/server-pg-migrations/20230315224203_create-deleted.sql')

diff --git a/crates/turtle/db/server-pg-migrations/20230315224203_create-deleted.sql b/crates/turtle/db/server-pg-migrations/20230315224203_create-deleted.sql
new file mode 100644
index 00000000..9a9e6263
--- /dev/null
+++ b/crates/turtle/db/server-pg-migrations/20230315224203_create-deleted.sql
@@ -0,0 +1,5 @@
+-- Add migration script here
+alter table history add column if not exists deleted_at timestamp;
+
+-- queries will all be selecting the ids of history for a user, that has been deleted
+create index if not exists history_deleted_index on history(client_id, user_id, deleted_at);
-- 
cgit v1.3.1

