From 724ddd5fe8e47e9245b8ba551e40af0688691b33 Mon Sep 17 00:00:00 2001 From: guillermo Date: Wed, 2 Oct 2024 09:26:23 +0200 Subject: [PATCH] refactor: refs #7980 Deleted table buyMark --- db/routines/vn/procedures/clean.sql | 6 ------ db/routines/vn2008/views/Compres_mark.sql | 8 -------- db/versions/11281-purpleCyca/00-firstScript.sql | 1 + 3 files changed, 1 insertion(+), 14 deletions(-) delete mode 100644 db/routines/vn2008/views/Compres_mark.sql create mode 100644 db/versions/11281-purpleCyca/00-firstScript.sql diff --git a/db/routines/vn/procedures/clean.sql b/db/routines/vn/procedures/clean.sql index 4a1f526fc..ad6d66e12 100644 --- a/db/routines/vn/procedures/clean.sql +++ b/db/routines/vn/procedures/clean.sql @@ -50,12 +50,6 @@ BEGIN DELETE FROM claim WHERE ticketCreated < v4Years; -- Robert ubicacion anterior de travelLog comentario para debug DELETE FROM zoneEvent WHERE `type` = 'day' AND dated < v3Months; - DELETE bm - FROM buyMark bm - JOIN buy b ON b.id = bm.id - JOIN entry e ON e.id = b.entryFk - JOIN travel t ON t.id = e.travelFk - WHERE t.landed <= v2Months; DELETE b FROM buy b JOIN entryConfig e ON e.defaultEntry = b.entryFk WHERE b.created < v2Months; diff --git a/db/routines/vn2008/views/Compres_mark.sql b/db/routines/vn2008/views/Compres_mark.sql deleted file mode 100644 index 7138c4e4c..000000000 --- a/db/routines/vn2008/views/Compres_mark.sql +++ /dev/null @@ -1,8 +0,0 @@ -CREATE OR REPLACE DEFINER=`root`@`localhost` - SQL SECURITY DEFINER - VIEW `vn2008`.`Compres_mark` -AS SELECT `bm`.`id` AS `Id_Compra`, - `bm`.`comment` AS `comment`, - `bm`.`mark` AS `mark`, - `bm`.`odbcDate` AS `odbc_date` -FROM `vn`.`buyMark` `bm` diff --git a/db/versions/11281-purpleCyca/00-firstScript.sql b/db/versions/11281-purpleCyca/00-firstScript.sql new file mode 100644 index 000000000..eadba5ae1 --- /dev/null +++ b/db/versions/11281-purpleCyca/00-firstScript.sql @@ -0,0 +1 @@ +DROP TABLE IF EXISTS vn.buyMark;