‎2018 Aug 15 9:46 AM
Hi all,
I am trying to create a script that populates a database with test data by duplicating a set of test data tables that I have.
Am having trouble getting it to work, any suggestions?
Sander
DROP PROCEDURE TEST;
CREATE PROCEDURE TEST ()
LANGUAGE SQLSCRIPT
READS SQL DATA AS
BEGIN
DECLARE i INT;
FOR i IN 1 .. 40 DO
create column table concatenate(copySCR1;:i) AS (SELECT * from "SRC1");
create column table concatenate(copySCR2;:i) AS (SELECT * from "SRC2");
create column table concatenate(copySCR3;:i) AS (SELECT * from "SRC3");
create column table concatenate(copySCR4;:i) AS (SELECT * from "SRC4");
END FOR;
END;
call TEST(?);