DELIMITER $$
DROP PROCEDURE IF EXISTS `world`.`DYNAMIC2_DEMO` $$
CREATE DEFINER=`tusa`@`%` PROCEDURE `DYNAMIC2_DEMO`(districtName VARCHAR(35))
BEGIN
DECLARE sql_string VARCHAR(400);
    loop_city:    BEGIN
                DROP TABLE IF EXISTS city_table;
                CREATE TABLE city_table (id INT, name VARCHAR(255), district varchar(255), CountryName char(53)) ENGINE=memory;
                SET sql_string = 'Insert INTO city_table (ID,Name, District, CountryName ) SELECT ID,Name,
                District, CountryCode FROM City where ID= ?' ;
                SET @SQL = sql_string;
                PREPARE s1 FROM @SQL;
                SET @x = 100;
                REPEAT SET @x = @x + 1;
                    EXECUTE s1 USING @x;
                UNTIL @x > 110
                END REPEAT;
                DEALLOCATE PREPARE s1;
                SELECT * FROM city_table;
                DROP TABLE IF EXISTS city_table;
    END loop_city;
END $$
DELIMITER ;

Latest conferences

We have 1974 guests and no members online