2024-01-15 11:31:03 +00:00
|
|
|
DELIMITER $$
|
|
|
|
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `stock`.`inbound_addPick`(
|
|
|
|
vSelf INT,
|
2024-04-08 07:11:40 +00:00
|
|
|
vOutboundFk INT,
|
|
|
|
vQuantity INT
|
2024-01-15 11:31:03 +00:00
|
|
|
)
|
|
|
|
BEGIN
|
|
|
|
INSERT INTO inboundPick
|
|
|
|
SET
|
|
|
|
inboundFk = vSelf,
|
|
|
|
outboundFk = vOutboundFk,
|
|
|
|
quantity = vQuantity
|
|
|
|
ON DUPLICATE KEY UPDATE
|
|
|
|
quantity = quantity + vQuantity;
|
|
|
|
END$$
|
|
|
|
DELIMITER ;
|