标签:city tab beijing work oca ict 插入数据 world robot
通过execute sql string关键字来执行对数据库的插入操作和删除操作。
(1)、向数据库中插入数据
connect to database using custom params | pymysql | database=‘world‘,user=‘root‘,password=‘root‘,host=‘localhost‘,port=3306 |
execute sql string |
insert into city(name,countrycode,district,population) values("beijing","zh","china","217100") |
|
disconnect from database |
(2)、从数据库中,删除数据
connect to database using custom params | pymysql | database=‘world‘,user=‘root‘,password=‘root‘,host=‘localhost‘,port=3306 |
execute sql string | delete from city where name = "beijing"; | |
disconnect from database |
robot framework——对mysql数据库进行插入和删除数据
标签:city tab beijing work oca ict 插入数据 world robot
原文地址:https://www.cnblogs.com/xiaobaibailongma/p/12250549.html