use moodle;
DROP PROCEDURE test_insert ;
DELIMITER ;;
CREATE PROCEDURE test_insert ()
BEGIN
DECLARE i INT DEFAULT 0;
WHILE i<3
DO
INSERT INTO moodle.mdl_question_attempt_step_data
(
attemptstepid,
name,
value
)
VALUES
(
81003+i,
'_finish',
'1'
);
SET i=i+1;
END WHILE ;
END;;
CALL test_insert();
Mysql 存储过程--实现两列递增插入
最新推荐文章于 2021-04-08 04:26:03 发布