当前位置:网站首页>1.3 mysql批量插入数据
1.3 mysql批量插入数据
2022-08-05 05:05:00 【LetsStudy】
DROP PROCEDURE
IF EXISTS test_data;
DELIMITER $$ //定界符
CREATE PROCEDURE test_data()
BEGIN
-- 定义变量
DECLARE i INT UNSIGNED DEFAULT 1; -- 定义变量i默认值
-- 循环次数
WHILE i <= 1000 DO -- 循环
INSERT INTO testdata_check(id,crawl_cfg_id,detection_type,crawl_file_info_id,task_instance_id,crawl_content) VALUES(CONCAT('17ac3e7419954b63878157491a4e8d42',i),'2','5',null,'1f9d7b13c0174dc0aa52f00a53014acf','{"url": "http://www.beijing.gov.cn/shipin/Interviewlive/558.html", "title": "北京市新型冠状病毒肺炎疫情防控工作新闻发布会(第253场)", "author": "", "domain": "beijing.gov.cn", "islist": "False", "content": "Reset
restore all settings to the default values", "send_time": "2022-07-29 17:32:52", "create_time": "2022-07-29 17:32:52", "islist_code": 0.1447209933229973, "publish_time": "2021-11-01"}');
SET i = i+1; -- 更新i的值
END WHILE; -- 结束循环
END $$
--
CALL test_data();
边栏推荐
猜你喜欢
随机推荐
Flutter learning - the beginning
Flutter学习三-Flutter基本结构和原理
Dephi逆向工具Dede导出函数名MAP导入到IDA中
uboot开启调试打印信息
Flutter learning 5-integration-packaging-publish
结构光三维重建(一)条纹结构光三维重建
数字_获取指定位数的小数
Flutter学习4-基本UI组件
AUTOCAD - dimension association
说说数据治理中常见的20个问题
Excel Paint
jvm 三 之堆与栈
Flutter real machine running and simulator running
关于sklearn库的安装
Redis - 13. Development Specifications
Flutter TapGestureRecognizer 如何工作
C language - vernacular to understand the original code, inverse code and complement code
社区分享|腾讯海外游戏基于JumpServer构建游戏安全运营能力
Detailed explanation of Mysql's undo log
WPF中DataContext作用