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

14 lines
336 B
MySQL
Raw Normal View History

DELIMITER $$
2024-08-20 08:06:10 +00:00
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`workerTimeControlSOWP`(IN vUserFk INT, IN vDated DATE)
BEGIN
SET @order := 0;
UPDATE workerTimeControl
SET `order` = @order := @order + 1
WHERE vUserFk =userFk
AND vDated = DATE(timed)
ORDER BY timed;
END$$
DELIMITER ;