From 7cf46fc6cd3cd0e0e7d218c64bba6d2cd40aaadb Mon Sep 17 00:00:00 2001 From: pako Date: Tue, 30 Jan 2024 10:12:27 +0100 Subject: [PATCH 1/2] incluye fecha de ayer --- db/routines/edi/procedures/ekt_scan.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/db/routines/edi/procedures/ekt_scan.sql b/db/routines/edi/procedures/ekt_scan.sql index 456e329e0..b8817906c 100644 --- a/db/routines/edi/procedures/ekt_scan.sql +++ b/db/routines/edi/procedures/ekt_scan.sql @@ -73,7 +73,7 @@ BEGIN INSERT INTO tmp.ekt SELECT id FROM ekt - WHERE fec = vFec + WHERE fec >= vFec - INTERVAL 1 DAY AND (( vKlo = vDefaultKlo AND (klo = vKlo OR klo IS NULL OR klo = 0) @@ -82,7 +82,7 @@ BEGIN AND auction = vAuction AND agj = vShortAgj) ) - ORDER BY agj DESC + ORDER BY agj DESC, fec DESC LIMIT 1; SELECT COUNT(*) FROM tmp.ekt INTO vIsFound; From 1124722b25bf182a335b20029c732b175a436891 Mon Sep 17 00:00:00 2001 From: pako Date: Tue, 30 Jan 2024 12:45:17 +0100 Subject: [PATCH 2/2] nuevo commit de prueba --- db/routines/edi/procedures/ekt_scan.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/db/routines/edi/procedures/ekt_scan.sql b/db/routines/edi/procedures/ekt_scan.sql index b8817906c..b0b75a6a7 100644 --- a/db/routines/edi/procedures/ekt_scan.sql +++ b/db/routines/edi/procedures/ekt_scan.sql @@ -2,7 +2,7 @@ DELIMITER $$ CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `edi`.`ekt_scan`(vBarcode VARCHAR(512)) BEGIN /** - * Busca transaciones a partir de un código de barras, las marca como escaneadas + * Busca transaciones a partir de un codigo de barras, las marca como escaneadas * y las devuelve. * Ver https://wiki.verdnatura.es/index.php/Ekt#Algoritmos_de_lectura *