Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
yotta
/
pictogram
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
60
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
05a863aa
authored
Nov 08, 2017
by
Arturo Montejo Ráez
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
new-grid adapt2 revision
parent
7beaabea
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
sails/roles/database/files/new-grid-system-adapt2.sql
sails/roles/database/files/new-grid-system-adapt2.sql
View file @
05a863aa
-- Correccion de integridad por error en DEV, antes de cambiar los nombres
SET
FOREIGN_KEY_CHECKS
=
0
;
SET
FOREIGN_KEY_CHECKS
=
0
;
-- Purgamos base de datos antes
DELETE
FROM
stu_picto
WHERE
id_scene
NOT
IN
(
SELECT
s
.
id
FROM
scene
s
);
DELETE
FROM
stu_picto
WHERE
id_scene
NOT
IN
(
SELECT
s
.
id
FROM
scene
s
);
ALTER
TABLE
`stu_picto`
ADD
CONSTRAINT
`stu_picto_scene_fk`
FOREIGN
KEY
(
`id_scene`
)
REFERENCES
`scene`
(
`id`
)
ON
DELETE
CASCADE
;
-- ----------------------------------------------------------------------------
-- ----------------------------------------------------------------------------
-- CAMBIOS EN EL SCHEMA DE pictodb
-- CAMBIOS EN EL SCHEMA DE pictodb
...
@@ -9,11 +9,11 @@ ALTER TABLE `stu_picto` ADD CONSTRAINT `stu_picto_scene_fk` FOREIGN KEY (`id_sce
...
@@ -9,11 +9,11 @@ ALTER TABLE `stu_picto` ADD CONSTRAINT `stu_picto_scene_fk` FOREIGN KEY (`id_sce
RENAME
TABLE
`scene`
TO
`grid`
;
RENAME
TABLE
`scene`
TO
`grid`
;
ALTER
TABLE
`student`
CHANGE
`id_active_scene`
`id_active_grid`
int
(
11
)
NULL
;
ALTER
TABLE
`student`
CHANGE
`id_active_scene`
`id_active_grid`
int
(
11
)
NULL
;
ALTER
TABLE
`stu_picto`
ADD
`id_grid`
int
(
11
)
NOT
NULL
;
ALTER
TABLE
`stu_picto`
ADD
`id_grid`
int
(
11
)
NOT
NULL
;
ALTER
TABLE
`stu_picto`
ADD
`id_child_grid`
int
(
11
)
NULL
;
ALTER
TABLE
`stu_picto`
ADD
`id_child_grid`
int
(
11
)
NULL
;
ALTER
TABLE
`stu_picto`
DROP
COLUMN
`id_scene`
;
ALTER
TABLE
`stu_picto`
DROP
COLUMN
`id_scene`
;
ALTER
TABLE
`stu_picto`
ADD
FOREIGN
KEY
(
id_child_grid
)
REFERENCES
grid
(
id
)
ON
DELETE
SET
NULL
;
ALTER
TABLE
`stu_picto`
ADD
FOREIGN
KEY
(
`id_child_grid`
)
REFERENCES
`grid`
(
`id`
)
ON
DELETE
SET
NULL
;
ALTER
TABLE
`stu_picto`
ADD
FOREIGN
KEY
(
`id_grid`
)
REFERENCES
`grid`
(
`id`
)
ON
DELETE
CASCADE
;
ALTER
TABLE
`grid`
DROP
COLUMN
`categories`
;
ALTER
TABLE
`grid`
DROP
COLUMN
`categories`
;
ALTER
TABLE
`grid`
ADD
`color`
varchar
(
7
)
NULL
;
ALTER
TABLE
`grid`
ADD
`color`
varchar
(
7
)
NULL
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment