8、insert、delete、update语句总结
insert常用语句
> insert into tb1 (name,age) values('tom',33);> insert into tb1 (name,age) values('jerry',22),('naruto',28);> insert into tb1 values (4,'Sasuke',28),(5,'hinata',25);> insert into tbl2 set id=2,name="test",age=18,gender='M';
delete常用语句
> delete from tb1;> delete from tb1 where age=22;> delete from tb1 where name rlike '^t.*';> delete from tb1 where age > 30 order by age desc limit 1;
update常用语句
> update tb1 set age = 28;> update tb1 set name='luffy' where id=13;> update tb1 set name='luffy',age=25 where id=13;
赞 (0)