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

15 lines
342 B
MySQL
Raw Permalink Normal View History

DELIMITER $$
2024-08-20 08:06:10 +00:00
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`buy_checkGrouping`(vGrouping INT)
BEGIN
/**
* Checks the buy grouping, throws an error if it's invalid.
*
* @param vGrouping The grouping
*/
IF vGrouping = 0 THEN
SIGNAL SQLSTATE '45000'
SET MESSAGE_TEXT = 'Grouping cannot be zero';
END IF;
END$$
DELIMITER ;