DELIMITER //

CREATE PROCEDURE run_sql_statements2()
BEGIN

SET @counter = 0;

WHILE @counter < 600 DO
    SET @random_column_name = CONCAT('column_', FLOOR(RAND() * 1000000) + 1);
    SET @alter_query = CONCAT('ALTER TABLE flights ADD COLUMN `', @random_column_name, '` INT(7)');
    PREPARE alter_stmt FROM @alter_query;
    EXECUTE alter_stmt;
    DEALLOCATE PREPARE alter_stmt;
    SET @counter = @counter + 1;
    SELECT sleep(.001);
END WHILE;


END //

CALL run_sql_statements2();
