DROP PROCEDURE dowhile ;
DELIMITER //
delimiter //
create procedure dowhile()
begin
DECLARE i INT DEFAULT 2;
start transaction ;
while i<50 do
insert into demos(names,pwds)
value('jxy','demosf');
set i=i+1;
end WHILE;
commit;
end //
CALL dowhile()
delimiter //
DELIMITER //
delimiter //
create procedure dowhile()
begin
DECLARE i INT DEFAULT 2;
start transaction ;
while i<50 do
insert into demos(names,pwds)
value('jxy','demosf');
set i=i+1;
end WHILE;
commit;
end //
CALL dowhile()
delimiter //