From 9e486e4affa8593546602921ef393a18caf7533e Mon Sep 17 00:00:00 2001 From: sergiodt Date: Tue, 30 Jul 2024 13:04:33 +0200 Subject: [PATCH] hotFix reallocate iss refs #6861 --- db/routines/vn/procedures/itemShelvingSale_reallocate.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/db/routines/vn/procedures/itemShelvingSale_reallocate.sql b/db/routines/vn/procedures/itemShelvingSale_reallocate.sql index 0ce4440e6..d5b89c373 100644 --- a/db/routines/vn/procedures/itemShelvingSale_reallocate.sql +++ b/db/routines/vn/procedures/itemShelvingSale_reallocate.sql @@ -30,7 +30,7 @@ BEGIN FROM itemShelvingSale iss JOIN itemShelving ish ON ish.id = iss.itemShelvingFk WHERE iss.itemShelvingFk = vItemShelvingFk - AND iss.itemFk = vItemFk + AND ish.itemFk = vItemFk AND NOT iss.isPicked FOR UPDATE; -- 2.40.1