salix/db/routines/vn/procedures/inventoryMakeLauncher.sql

13 lines
302 B
MySQL
Raw Normal View History

DELIMITER $$
2024-08-20 08:06:10 +00:00
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`inventoryMakeLauncher`()
BEGIN
/**
2024-02-15 09:04:15 +00:00
* Recalculate the inventories of all warehouses
*/
2024-02-15 09:04:15 +00:00
CALL inventoryMake(
util.VN_CURDATE() -
INTERVAL (SELECT daysInPastForInventory FROM inventoryConfig LIMIT 1) DAY
);
END$$
DELIMITER ;