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

21 lines
377 B
MySQL
Raw Normal View History

DELIMITER $$
2024-08-20 08:06:10 +00:00
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`buy_recalcPricesByBuy`(
vBuyFk INT(11)
)
BEGIN
/**
* Recalcula los precios de una compra
*
* @param vBuyFk
*/
DROP TEMPORARY TABLE IF EXISTS tmp.buyRecalc;
CREATE TEMPORARY TABLE tmp.buyRecalc
SELECT vBuyFk id;
CALL buy_recalcPrices();
DROP TEMPORARY TABLE tmp.buyRecalc;
END$$
DELIMITER ;