1CREATE PROCEDURE randomizer()
2BEGIN
3 DECLARE i INT DEFAULT 0;
4 DECLARE random CHAR(20) ;
5 theloop: loop
6 SET random = CONV(FLOOR(RAND() * 99999999999999), 20, 36);
7 INSERT INTO test VALUES (i+1, random);
8 SET i=i+1;
9 IF i = 500000 THEN
10 LEAVE theloop;
11 END IF;
12 END LOOP theloop;
13END
14