From 94f4d9740bb27689e7069052e3b3e97ccc42fab8 Mon Sep 17 00:00:00 2001 From: Robbie Blaine Date: Fri, 10 Nov 2023 12:13:48 +0200 Subject: [PATCH] Re-add `FOR NO KEY UPDATE` to `FETCH_QUERY_UPDATE` Signed-off-by: Robbie Blaine --- askar-storage/src/backend/postgres/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/askar-storage/src/backend/postgres/mod.rs b/askar-storage/src/backend/postgres/mod.rs index e7418ea5..e2e6a65a 100644 --- a/askar-storage/src/backend/postgres/mod.rs +++ b/askar-storage/src/backend/postgres/mod.rs @@ -100,7 +100,7 @@ const FETCH_QUERY_UPDATE: &str = " * FROM fetched_data - FOR UPDATE"; + FOR NO KEY UPDATE"; const INSERT_QUERY: &str = "INSERT INTO items (profile_id, kind, category, name, value, expiry) VALUES ($1, $2, $3, $4, $5, $6) ON CONFLICT DO NOTHING RETURNING id";