diff options
| author | nsfisis <nsfisis@gmail.com> | 2024-08-12 05:54:49 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2024-08-12 05:54:49 +0900 |
| commit | 3074f8d74330a2c238040755b758230d682a4bc4 (patch) | |
| tree | 3c45267ee25aa78be1ad4c31e0c09894e656b506 /backend/query.sql | |
| parent | 7527e54bba0c528015ce402bfa4534c1ab6ca1da (diff) | |
| parent | b37d6f213c2f3b19631e5067f39a7106859faaed (diff) | |
| download | phperkaigi-2025-albatross-3074f8d74330a2c238040755b758230d682a4bc4.tar.gz phperkaigi-2025-albatross-3074f8d74330a2c238040755b758230d682a4bc4.tar.zst phperkaigi-2025-albatross-3074f8d74330a2c238040755b758230d682a4bc4.zip | |
Merge branch 'feat/play-page'
Diffstat (limited to 'backend/query.sql')
| -rw-r--r-- | backend/query.sql | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/backend/query.sql b/backend/query.sql index 408bf2d..25eb4df 100644 --- a/backend/query.sql +++ b/backend/query.sql @@ -78,6 +78,11 @@ INSERT INTO submissions (game_id, user_id, code, code_size, code_hash) VALUES ($1, $2, $3, $4, $5) RETURNING submission_id; +-- name: GetSubmissionCodeSizeByID :one +SELECT code_size FROM submissions +WHERE submission_id = $1 +LIMIT 1; + -- name: ListTestcasesByGameID :many SELECT * FROM testcases WHERE testcases.problem_id = (SELECT problem_id FROM games WHERE game_id = $1) |
