From 1ffbb30d77689ffc9dd9e7c219c5f335a3ada3f0 Mon Sep 17 00:00:00 2001 From: josepd Date: Fri, 2 Feb 2024 14:05:27 +0100 Subject: [PATCH 1/2] refs #6689 feat: delete view vn2008 --- db/routines/vn2008/views/Prioridades.sql | 6 ------ db/routines/vn2008/views/person_user.sql | 10 ---------- db/routines/vn2008/views/person_user_idtrabajador.sql | 9 --------- db/routines/vn2008/views/reference_min.sql | 7 ------- db/versions/10869-crimsonDracena/00-firstScript.sql | 1 + 5 files changed, 1 insertion(+), 32 deletions(-) delete mode 100644 db/routines/vn2008/views/Prioridades.sql delete mode 100644 db/routines/vn2008/views/person_user.sql delete mode 100644 db/routines/vn2008/views/person_user_idtrabajador.sql delete mode 100644 db/routines/vn2008/views/reference_min.sql create mode 100644 db/versions/10869-crimsonDracena/00-firstScript.sql diff --git a/db/routines/vn2008/views/Prioridades.sql b/db/routines/vn2008/views/Prioridades.sql deleted file mode 100644 index 7e89a538f..000000000 --- a/db/routines/vn2008/views/Prioridades.sql +++ /dev/null @@ -1,6 +0,0 @@ -CREATE OR REPLACE DEFINER=`root`@`localhost` - SQL SECURITY DEFINER - VIEW `vn2008`.`Prioridades` -AS SELECT `qp`.`id` AS `Id_Prioridad`, - `qp`.`priority` AS `Prioridad` -FROM `vn`.`queuePriority` `qp` diff --git a/db/routines/vn2008/views/person_user.sql b/db/routines/vn2008/views/person_user.sql deleted file mode 100644 index 1fb470c88..000000000 --- a/db/routines/vn2008/views/person_user.sql +++ /dev/null @@ -1,10 +0,0 @@ -CREATE OR REPLACE DEFINER=`root`@`localhost` - SQL SECURITY DEFINER - VIEW `vn2008`.`person_user` -AS SELECT `u`.`id` AS `id`, - `u`.`role` AS `mysql_user_id`, - `u`.`name` AS `name`, - `u`.`password` AS `password`, - `u`.`active` AS `active`, - `u`.`lastPassChange` AS `last_pass_change` -FROM `account`.`user` `u` diff --git a/db/routines/vn2008/views/person_user_idtrabajador.sql b/db/routines/vn2008/views/person_user_idtrabajador.sql deleted file mode 100644 index 1eb45f464..000000000 --- a/db/routines/vn2008/views/person_user_idtrabajador.sql +++ /dev/null @@ -1,9 +0,0 @@ -CREATE OR REPLACE DEFINER=`root`@`localhost` - SQL SECURITY DEFINER - VIEW `vn2008`.`person_user_idtrabajador` -AS SELECT `t`.`Id_Trabajador` AS `Id_Trabajador` -FROM ( - `vn2008`.`person_user` `p` - JOIN `vn2008`.`Trabajadores` `t` ON(`p`.`id` = `t`.`user_id`) - ) -WHERE `t`.`user_id` = `account`.`myUser_getId`() diff --git a/db/routines/vn2008/views/reference_min.sql b/db/routines/vn2008/views/reference_min.sql deleted file mode 100644 index d40ae12a3..000000000 --- a/db/routines/vn2008/views/reference_min.sql +++ /dev/null @@ -1,7 +0,0 @@ -CREATE OR REPLACE DEFINER=`root`@`localhost` - SQL SECURITY DEFINER - VIEW `vn2008`.`reference_min` -AS SELECT `rc`.`dated` AS `date`, - `rc`.`value` AS `rate`, - `rc`.`currencyFk` AS `moneda_id` -FROM `vn`.`referenceCurrent` `rc` diff --git a/db/versions/10869-crimsonDracena/00-firstScript.sql b/db/versions/10869-crimsonDracena/00-firstScript.sql new file mode 100644 index 000000000..e5e3c3a4b --- /dev/null +++ b/db/versions/10869-crimsonDracena/00-firstScript.sql @@ -0,0 +1 @@ +REVOKE SELECT ON TABLE reference_min FROM logistic; From e704f2eaf7387f569fb5b56da9bd5c527b75e22a Mon Sep 17 00:00:00 2001 From: josepd Date: Mon, 5 Feb 2024 07:11:50 +0100 Subject: [PATCH 2/2] feat: refs #6689 Deleted view vn2008 --- db/versions/10869-crimsonDracena/00-firstScript.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/db/versions/10869-crimsonDracena/00-firstScript.sql b/db/versions/10869-crimsonDracena/00-firstScript.sql index e5e3c3a4b..0042d24e3 100644 --- a/db/versions/10869-crimsonDracena/00-firstScript.sql +++ b/db/versions/10869-crimsonDracena/00-firstScript.sql @@ -1 +1 @@ -REVOKE SELECT ON TABLE reference_min FROM logistic; +REVOKE SELECT ON TABLE vn2008.reference_min FROM logistic;