From 10db5103da96d427b37214341cfe3be7789066a6 Mon Sep 17 00:00:00 2001 From: norohind <60548839+norohind@users.noreply.github.com> Date: Mon, 17 Jan 2022 01:30:52 +0300 Subject: [PATCH] DB schema: add index by timestamp --- model/postgres_sql_requests.py | 1 + 1 file changed, 1 insertion(+) diff --git a/model/postgres_sql_requests.py b/model/postgres_sql_requests.py index f21ed6e..6e37b62 100644 --- a/model/postgres_sql_requests.py +++ b/model/postgres_sql_requests.py @@ -12,6 +12,7 @@ timestamp timestamp default timezone('utc', now())); create index if not exists idx_action_id_0 on squads_stats_states (action_id); create index if not exists idx_platform_leaderboard_type_1 on squads_stats_states(platform, leaderboard_type); +create index if not exists idx_timestamp_0 on squads_stats_states(timestamp); """ select_last_action_id = """select action_id