首页 > 技术文章 > mysql 数据的增删改

zhangqing979797 2018-10-16 21:32 原文

1.更新数据update

update 表名 set

字段1 = 值

字段2 = 值2

where condition

示例:

update mysql.user set password=password("123)where user="root'' and host ="localhost";

2.删除数据

delete from 表名 

where conition

示例;

delete from mysql.user where password=" ''

 

推荐阅读