8144-devToTest_2448 #3216
|
@ -1,4 +1,4 @@
|
|||
CREATE OR REPLACE TEMPORARY TABLE tItemShelving
|
||||
CREATE OR REPLACE TEMPORARY TABLE tmp.tItemShelving
|
||||
(PRIMARY KEY (id))
|
||||
ENGINE = MEMORY
|
||||
SELECT ish.id, s.id shelvingFk
|
||||
|
@ -12,7 +12,7 @@ UPDATE vn.itemShelving ish
|
|||
JOIN tItemShelving tish ON tish.id = ish.id
|
||||
SET ish.shelvingFk = tish.shelvingFk;
|
||||
|
||||
DROP TEMPORARY TABLE tItemShelving;
|
||||
DROP TEMPORARY TABLE tmp.tItemShelving;
|
||||
|
||||
ALTER TABLE vn.itemShelving
|
||||
ADD CONSTRAINT itemShelving_shelving_FK FOREIGN KEY (shelvingFk) REFERENCES vn.shelving(id)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
CREATE OR REPLACE TEMPORARY TABLE tItemShelvingLog
|
||||
CREATE OR REPLACE TEMPORARY TABLE tmp.tItemShelvingLog
|
||||
(PRIMARY KEY (id))
|
||||
ENGINE = MEMORY
|
||||
SELECT ishl.id, s.id shelvingFk
|
||||
|
@ -11,4 +11,4 @@ UPDATE vn.itemShelvingLog ishl
|
|||
JOIN tItemShelvingLog tishl ON tishl.id = ishl.id
|
||||
SET ishl.shelvingFk = tishl.shelvingFk;
|
||||
|
||||
DROP TEMPORARY TABLE tItemShelvingLog;
|
||||
DROP TEMPORARY TABLE tmp.tItemShelvingLog;
|
||||
|
|
Loading…
Reference in New Issue