Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into 7565-testToMaster
gitea/salix/pipeline/pr-master This commit looks good
Details
gitea/salix/pipeline/pr-master This commit looks good
Details
This commit is contained in:
commit
282cf96336
|
@ -8,6 +8,8 @@ BEGIN
|
|||
END;
|
||||
|
||||
CREATE OR REPLACE TEMPORARY TABLE tSalesToPreserve
|
||||
(PRIMARY KEY (id))
|
||||
ENGINE = MEMORY
|
||||
SELECT s.id, s.itemFk, SUM(s.quantity) newQuantity
|
||||
FROM sale s
|
||||
JOIN item i ON i.id = s.itemFk
|
||||
|
@ -20,7 +22,7 @@ BEGIN
|
|||
|
||||
UPDATE sale s
|
||||
JOIN tSalesToPreserve stp ON stp.id = s.id
|
||||
SET quantity = newQuantity
|
||||
SET s.quantity = newQuantity
|
||||
WHERE s.ticketFk = vTicketFk;
|
||||
|
||||
DELETE s.*
|
||||
|
|
Loading…
Reference in New Issue