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

34 lines
699 B
MySQL
Raw Permalink Normal View History

DELIMITER $$
2024-11-13 08:03:44 +00:00
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`itemShelving_get`(
vShelvingCode VARCHAR(10)
)
BEGIN
/**
2024-11-13 08:03:44 +00:00
* Lista artículos de itemShelving.
*
2024-11-13 08:03:44 +00:00
* @param vShelvingCode Matrícula del carro
**/
SELECT ish.itemFk item,
2024-11-04 07:59:10 +00:00
i.name,
i.longName,
i.size,
ish.visible,
ish.packing,
ish.grouping,
p.code,
ish.id,
s.priority,
2024-02-09 06:51:51 +00:00
ish.isChecked,
2024-07-31 16:11:03 +00:00
ic.url,
2024-11-04 06:48:28 +00:00
ish.available,
ish.buyFk,
ish.shelvingFk
FROM itemShelving ish
JOIN item i ON i.id = ish.itemFk
2024-11-13 08:03:44 +00:00
JOIN shelving s ON s.id = ish.shelvingFk
LEFT JOIN parking p ON p.id = s.parkingFk
2024-02-09 06:51:51 +00:00
JOIN hedera.imageConfig ic
2024-11-13 08:03:44 +00:00
WHERE s.code COLLATE utf8_unicode_ci = vShelvingCode;
END$$
DELIMITER ;