refs #6372 feat: vn2008 to vn
gitea/salix/pipeline/pr-dev Build queued... Details

This commit is contained in:
David Domenech 2024-02-06 07:37:33 +01:00
parent da0fe2d83a
commit b7bb1b9784
4 changed files with 7 additions and 27 deletions

View File

@ -1,8 +0,0 @@
CREATE OR REPLACE DEFINER=`root`@`localhost`
SQL SECURITY DEFINER
VIEW `vn2008`.`link`
AS SELECT
`l`.`clientFk` AS `Id_Cliente`,
`l`.`supplierFk` AS `Id_Proveedor`
FROM
`vn`.`link` `l`;

View File

@ -1,11 +0,0 @@
ALTER TABLE IF EXISTS `vn2008`.`link` RENAME `vn`.`link`;
ALTER TABLE IF EXISTS `vn`.`link`
CHANGE COLUMN IF EXISTS `Id_Cliente` `clientFk` int(11) NOT NULL,
CHANGE COLUMN IF EXISTS `Id_Proveedor` `supplierFk` int(11) NOT NULL;
ALTER TABLE IF EXISTS vn.link MODIFY COLUMN supplierFk int(10) unsigned NOT NULL;
ALTER TABLE IF EXISTS vn.link ADD CONSTRAINT link_client_FK FOREIGN KEY (clientFk) REFERENCES vn.client(id) ON DELETE CASCADE ON UPDATE CASCADE;
ALTER TABLE IF EXISTS vn.link ADD CONSTRAINT link_supplier_FK FOREIGN KEY (supplierFk) REFERENCES vn.supplier(id) ON DELETE CASCADE ON UPDATE CASCADE;

View File

@ -153,3 +153,6 @@ ALTER TABLE IF EXISTS vn2008.jerarquia__ COMMENT='refs #6372 @deprecated 2023-12
ALTER TABLE IF EXISTS vn2008.language RENAME vn2008.language__; ALTER TABLE IF EXISTS vn2008.language RENAME vn2008.language__;
ALTER TABLE IF EXISTS vn2008.language__ COMMENT='refs #6372 @deprecated 2023-12-13;'; ALTER TABLE IF EXISTS vn2008.language__ COMMENT='refs #6372 @deprecated 2023-12-13;';
ALTER TABLE IF EXISTS vn2008.link RENAME vn2008.link__;
ALTER TABLE IF EXISTS vn2008.link__ COMMENT='refs #6372 @deprecated 2023-12-13;';

View File

@ -13,14 +13,10 @@ VIEW `vn2008`.`integra2_province` AS
GRANT SELECT ON TABLE vn2008.integra2_province TO `employee`; GRANT SELECT ON TABLE vn2008.integra2_province TO `employee`;
GRANT SELECT ON TABLE vn.integra2Province TO `employee`; GRANT SELECT ON TABLE vn.integra2Province TO `employee`;
-- link -- link
CREATE OR REPLACE DEFINER=`root`@`localhost`
SQL SECURITY DEFINER GRANT SELECT ON TABLE vn.company TO `administrative`;
VIEW `vn2008`.`link` AS GRANT SELECT ON TABLE vn.company TO `hr`;
SELECT 1;
GRANT SELECT ON TABLE vn2008.link TO `administrative`;
GRANT SELECT ON TABLE vn.link TO `administrative`;
GRANT SELECT ON TABLE vn2008.link TO `hr`;
GRANT SELECT ON TABLE vn.link TO `hr`;
-- warehouse_pickup -- warehouse_pickup
CREATE OR REPLACE DEFINER=`root`@`localhost` CREATE OR REPLACE DEFINER=`root`@`localhost`
SQL SECURITY DEFINER SQL SECURITY DEFINER