From 125e26b4d5c986f8531c098ecd5d291c1e1c7a76 Mon Sep 17 00:00:00 2001
From: nsfisis <nsfisis@gmail.com>
Date: Sun, 11 Aug 2024 20:39:48 +0900
Subject: feat(backend): make `games.problem_id` non-null

---
 backend/query.sql | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

(limited to 'backend/query.sql')

diff --git a/backend/query.sql b/backend/query.sql
index bcbee12..408bf2d 100644
--- a/backend/query.sql
+++ b/backend/query.sql
@@ -30,12 +30,12 @@ SELECT EXISTS (
 
 -- name: ListGames :many
 SELECT * FROM games
-LEFT JOIN problems ON games.problem_id = problems.problem_id
+JOIN problems ON games.problem_id = problems.problem_id
 ORDER BY games.game_id;
 
 -- name: ListGamesForPlayer :many
 SELECT * FROM games
-LEFT JOIN problems ON games.problem_id = problems.problem_id
+JOIN problems ON games.problem_id = problems.problem_id
 JOIN game_players ON games.game_id = game_players.game_id
 WHERE game_players.user_id = $1
 ORDER BY games.game_id;
@@ -52,7 +52,7 @@ WHERE game_id = $1;
 
 -- name: GetGameByID :one
 SELECT * FROM games
-LEFT JOIN problems ON games.problem_id = problems.problem_id
+JOIN problems ON games.problem_id = problems.problem_id
 WHERE games.game_id = $1
 LIMIT 1;
 
-- 
cgit v1.3.1

