选择在tea表中选择teaage等于19岁,叫汪雪的
select*from tea where teaage=‘19‘&&stuname=‘张雪‘
在stu找出大于20岁的女同学的姓名、学号
select stuname,stuid from stu where teaage=‘19‘&&stusex=‘女‘;
选择tea表中teaname有姓李
select*from tea where teaname like ‘李%‘;
在tea表中teaage按降序方法来排序
select*from tea order byteaage desc;
在tea中给teaidA0006的teasex改为女
update tea set teasex=where teaid =‘A0006‘;
删除一行id=1
delete from 表明 where id=1;
给root授权
grant all privileges on *.*(备注指所有库,具体可以是mysql)to ‘root‘ @ %(所有ip具体192.168.1.117) identified by ‘123456‘(密码)。
rpm -q查询rpm 包是否安装
本文出自 “11106201” 博客,转载请与作者联系!
原文:http://11116201.blog.51cto.com/11106201/1735553