From 1e9868bacfbed29fec7a334b8c533715dc8a46ff Mon Sep 17 00:00:00 2001 From: Daniel Ponte Date: Sun, 21 Jul 2024 10:55:49 -0400 Subject: [PATCH] Fix duplicate due to unique --- sql/postgres/migrations/001_initial.up.sql | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sql/postgres/migrations/001_initial.up.sql b/sql/postgres/migrations/001_initial.up.sql index c601fb8..c2d9fb1 100644 --- a/sql/postgres/migrations/001_initial.up.sql +++ b/sql/postgres/migrations/001_initial.up.sql @@ -18,8 +18,6 @@ CREATE TABLE IF NOT EXISTS api_keys( api_key UUID UNIQUE NOT NULL ); -CREATE INDEX IF NOT EXISTS api_keys_api_key ON api_keys(api_key); - CREATE TABLE IF NOT EXISTS systems( id INTEGER PRIMARY KEY, name TEXT NOT NULL @@ -64,7 +62,7 @@ CREATE TABLE IF NOT EXISTS calls( CREATE INDEX IF NOT EXISTS calls_transcript_idx ON calls USING GIN (to_tsvector('english', transcript)); -CREATE INDEX IF NOT EXISTS calls_call_date_tg_idx ON calls(talkgroup, call_date); +CREATE INDEX IF NOT EXISTS calls_call_date_tg_idx ON calls(system, talkgroup, call_date); CREATE TABLE IF NOT EXISTS settings( name TEXT PRIMARY KEY,