Merge branch 'ent-671-fallo-en-el-migrate-de-la-6-a-la-7-en-tbackup' into 'develop'
Added procedure to avoid migrate fail in tbackup See merge request !328
This commit is contained in:
commit
d3ac848caf
|
@ -1291,9 +1291,19 @@ UPDATE twidget_dashboard SET id_widget = (SELECT id FROM twidget WHERE unique_na
|
|||
DELETE FROM twidget WHERE unique_name = 'graph_availability';
|
||||
|
||||
-- ---------------------------------------------------------------------
|
||||
-- Table `tbackup`
|
||||
-- Table `tbackup` (Extension table. Modify only if exists)
|
||||
-- ---------------------------------------------------------------------
|
||||
ALTER TABLE tbackup ADD COLUMN `filepath` varchar(512) NOT NULL DEFAULT "";
|
||||
delimiter //
|
||||
CREATE PROCEDURE addcol()
|
||||
BEGIN
|
||||
SET @vv1 = (SELECT COUNT(*) FROM information_schema.tables WHERE table_schema = DATABASE() AND table_name = 'tbackup');
|
||||
IF @vv1>0 THEN
|
||||
ALTER TABLE tbackup ADD COLUMN `filepath` varchar(512) NOT NULL DEFAULT "";
|
||||
END IF;
|
||||
END;
|
||||
//
|
||||
CALL addcol();
|
||||
DROP PROCEDURE addcol;
|
||||
|
||||
-- ---------------------------------------------------------------------
|
||||
-- Table `tconfig`
|
||||
|
|
Loading…
Reference in New Issue