fix: collection_new
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:
parent
d5f18b9187
commit
4f9b6030e8
|
@ -200,14 +200,6 @@ BEGIN
|
|||
OR pb.hasPlantTray;
|
||||
END IF;
|
||||
|
||||
-- Hay que excluir aquellos que no tengan la misma hora de preparacion, si procede
|
||||
IF vHasUniqueCollectionTime THEN
|
||||
DELETE pb
|
||||
FROM tmp.productionBuffer pb
|
||||
JOIN tmp.productionBuffer pb2 ON pb2.ticketFk = vFirstTicketFk
|
||||
AND (pb.HH <> pb2.HH OR pb.mm <> pb2.mm);
|
||||
END IF;
|
||||
|
||||
SELECT ticketFk INTO vFirstTicketFk
|
||||
FROM tmp.productionBuffer
|
||||
ORDER BY HH,
|
||||
|
@ -219,6 +211,14 @@ BEGIN
|
|||
routeFk,
|
||||
ticketFk
|
||||
LIMIT 1;
|
||||
|
||||
-- Hay que excluir aquellos que no tengan la misma hora de preparacion, si procede
|
||||
IF vHasUniqueCollectionTime THEN
|
||||
DELETE pb
|
||||
FROM tmp.productionBuffer pb
|
||||
JOIN tmp.productionBuffer pb2 ON pb2.ticketFk = vFirstTicketFk
|
||||
AND (pb.HH <> pb2.HH OR pb.mm <> pb2.mm);
|
||||
END IF;
|
||||
|
||||
SET vTicketFk = vFirstTicketFk;
|
||||
SET @lines = 0;
|
||||
|
|
Loading…
Reference in New Issue