From c525f80fe9f90bf971125d401e22f54c1762f238 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maximilian=20Ke=C3=9Fler?= Date: Sun, 24 Dec 2023 23:39:34 +0100 Subject: [PATCH] postgres: add table alias to query --- src/render_site.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/render_site.py b/src/render_site.py index 79eae9c..a1e84da 100644 --- a/src/render_site.py +++ b/src/render_site.py @@ -460,14 +460,14 @@ def get_player_list() -> List[Dict]: " WHERE user_ratings.user_id = users.id AND user_ratings.rating_type = 0" " ORDER BY league_id DESC" " LIMIT 1" - " ) ON TRUE " + " ) AS nv_rating_table ON TRUE " " LEFT JOIN LATERAL (" " SELECT value_after AS cs_rating" " FROM user_ratings" " WHERE user_ratings.user_id = users.id AND user_ratings.rating_type = 1" " ORDER BY league_id DESC" " LIMIT 1" - " ) ON TRUE " + " ) AS cs_rating_table ON TRUE " ")" "SELECT" " player_name AS name,"