MySQL update语句和insert插入语句写法完全不一样啊,不要搞混

1.mysql update 语句:

update user set name = 'xiaoming',age = 18 

where uid = 3000;

更新记录时update操作也不需要写table关键字,像insert into一样,不需要写table关键字,直接写表名即可

2.mysql insert 语句:

insert into user(uid,age,name,address) values(1000,18,'xiaohong','hunanyiyang')

posted @ 2016-12-14 19:02  跨境电商杂货铺  阅读(4621)  评论(0)    收藏  举报