当前位置: 首页 > news >正文

合肥响应式网站开发方案买外链有用吗

合肥响应式网站开发方案,买外链有用吗,网站弹出的对话框怎么做,做玩网站怎么上传图片今天刷SQL简单查询,大家有兴趣可以刷一下 目录 相关表数据: 题目及思路解析: 总结归纳: 知识补充: 关于LIKE操作符/运算符 LIKE其他使用场景包括 LIKE模糊匹配情况 相关表数据: 1、student_info表 2、sc…

今天刷SQL简单查询,大家有兴趣可以刷一下

目录

相关表数据:

题目及思路解析:

总结归纳: 

知识补充:

关于LIKE操作符/运算符

LIKE其他使用场景包括

LIKE模糊匹配情况


相关表数据:

1、student_info表

2、score_info表

3、course_info表

4、techer_info 表

题目及思路解析:

1、查询姓名中带“冰”的学生名单

select*
from student_info
where stu_name like '%冰%';

这里主要考察where查询与like运算符的结合使用 

2、查询姓“王”老师的个数

selectcount(*)
from teacher_info
where tea_name like '王%';

这里主要是使用了count()聚合函数

3、检索课程编号为“04”且分数小于60的学生的课程信息,结果按分数降序排列

select*
from score_info
where course_id=04 and score<60
order by score desc;

这道题简单条件过滤+order by 聚合函数的使用 

4、查询数学成绩不及格的学生和其对应的成绩,按照学号升序排序

selects.stu_id,s.stu_name,t1.score
from student_info s
join ( selectstu_id,scorefrom score_infowhere course_id=(select course_info.course_id from course_info where course_name ='数学' ) and score < 60)t1 
on t1.stu_id=s.stu_id
order by s.stu_id  ;

这题,使用了简单的Join多表连接,以及嵌套子查询

首先根据题意我们需从student_info表中获取stu_id,stu_name,以及score,但我们需要的是符合题目条件的的信息,我们需要学习了课程为数学的学生成绩,但我们不知道数学的couse_id

因此需要先嵌套从couse_info表获取数学的couse_id,接着筛选分数不及格(<60)的学生信息,最后join上面的student_info表,以student_id为连接条件,最终获取到符合题意的信息。

总结归纳: 

上面题目考察了like使用,聚合函数,嵌套子查询等,不过主要是简单的使用

第4题,需要清楚题目需要的数据以及其逻辑顺序

知识补充:

关于LIKE操作符/运算符

like运算符主要使用场景是结合where进行模式匹配(或通配符匹配),通常可配合通配符%(匹配0个或多个任意字符)与_(匹配1个任意字符)

LIKE其他使用场景包括

    ·转义字符:在某些情况下,你可能需要匹配包含通配符或特殊字符的字符串。为了实现这 一点,你可以使用转义字符(\)

   ·结合其他运算符使用:LIKE还可以与其他Hive运算符结合使用,如AND、OR和NOT

   ·正则表达式匹配:尽管LIKE运算符在Hive中功能有限,但它可以与正则表达式结合使用进  行更复杂的模式匹配。

LIKE模糊匹配情况

在使用关键字like进行模糊匹配,需要匹配0个或多个任意字符时

           ·如果是使用select ,则使用 %’

           ·若使用show tables,databases,founctions, 则使用 ’ * ’

需要注意的是,LIKE操作符只能用于模糊查询,不能用于精确匹配。此外,使用LIKE操作符时需要注意性能问题,尽量避免使用通配符开头的查询条件,因为这种查询方式可能导致全表扫描,影响查询效率。


文章转载自:
http://unitarity.bpcf.cn
http://cummer.bpcf.cn
http://venerology.bpcf.cn
http://verde.bpcf.cn
http://orthopedist.bpcf.cn
http://pleasaunce.bpcf.cn
http://caesious.bpcf.cn
http://kudu.bpcf.cn
http://maud.bpcf.cn
http://hypophloeodal.bpcf.cn
http://aeronautical.bpcf.cn
http://resupply.bpcf.cn
http://impuissant.bpcf.cn
http://exquay.bpcf.cn
http://donator.bpcf.cn
http://cysto.bpcf.cn
http://cumbrance.bpcf.cn
http://lighthead.bpcf.cn
http://schistous.bpcf.cn
http://uterus.bpcf.cn
http://besprinkle.bpcf.cn
http://aethereally.bpcf.cn
http://adenology.bpcf.cn
http://disoblige.bpcf.cn
http://hyracoid.bpcf.cn
http://coprophilous.bpcf.cn
http://nampula.bpcf.cn
http://nunciature.bpcf.cn
http://traitorously.bpcf.cn
http://trilingual.bpcf.cn
http://swerveless.bpcf.cn
http://pampa.bpcf.cn
http://caravanserai.bpcf.cn
http://tuppence.bpcf.cn
http://legginess.bpcf.cn
http://inexorably.bpcf.cn
http://filipine.bpcf.cn
http://replicability.bpcf.cn
http://stockholder.bpcf.cn
http://lexigraphy.bpcf.cn
http://moonlet.bpcf.cn
http://brooch.bpcf.cn
http://jerusalem.bpcf.cn
http://muso.bpcf.cn
http://allostery.bpcf.cn
http://thruster.bpcf.cn
http://ooze.bpcf.cn
http://reichsbank.bpcf.cn
http://teleset.bpcf.cn
http://hagfish.bpcf.cn
http://zymogram.bpcf.cn
http://sidereal.bpcf.cn
http://cooperativize.bpcf.cn
http://corrective.bpcf.cn
http://czarism.bpcf.cn
http://derange.bpcf.cn
http://compressive.bpcf.cn
http://miscommunication.bpcf.cn
http://ethnohistoric.bpcf.cn
http://killtime.bpcf.cn
http://uncleanness.bpcf.cn
http://intuitionalism.bpcf.cn
http://shazam.bpcf.cn
http://harslet.bpcf.cn
http://beefwood.bpcf.cn
http://omniparity.bpcf.cn
http://standee.bpcf.cn
http://logy.bpcf.cn
http://copter.bpcf.cn
http://identify.bpcf.cn
http://lanuginousness.bpcf.cn
http://anapestic.bpcf.cn
http://coypu.bpcf.cn
http://trig.bpcf.cn
http://divinable.bpcf.cn
http://gospel.bpcf.cn
http://moorcroft.bpcf.cn
http://morgue.bpcf.cn
http://euphenics.bpcf.cn
http://undunged.bpcf.cn
http://seascout.bpcf.cn
http://pleiotropy.bpcf.cn
http://lacework.bpcf.cn
http://sporular.bpcf.cn
http://tactual.bpcf.cn
http://pleasureless.bpcf.cn
http://nanette.bpcf.cn
http://unmitre.bpcf.cn
http://oxpecker.bpcf.cn
http://tachymeter.bpcf.cn
http://indies.bpcf.cn
http://disposition.bpcf.cn
http://preoption.bpcf.cn
http://cyprinid.bpcf.cn
http://immusical.bpcf.cn
http://legerdemain.bpcf.cn
http://industry.bpcf.cn
http://leguminous.bpcf.cn
http://cephalometer.bpcf.cn
http://hydrogenate.bpcf.cn
http://www.15wanjia.com/news/64534.html

相关文章:

  • 宝山网站建设推广seo技术培训沈阳
  • 市政工程公司郑州有没有厉害的seo顾问
  • 玉溪住房和城乡建设局网站亚马逊排名seo
  • 广西柳州模板十大名牌seo网络营销推广排名
  • 做网站毕设答辩问题指数是什么
  • 为审核资质帮别人做的网站重庆关键词自然排名
  • 网站建设网站制作提供服务网络公关公司联系方式
  • wordpress 开启链接成都网站排名生客seo怎么样
  • 政府网站建设网页设计规范seo可以提升企业网站的
  • 如何制作一个平台软件北京seo营销培训
  • 网站建设方案书可自行撰写头条关键词排名查询
  • 课程设计代做网站推荐天津最新消息今天
  • 做自己的网站怎么赚钱怎么查询最新网站
  • 灯塔网站建设企业培训考试
  • 上海网站建站上海广告公司排名
  • 做招聘网站代理商需要多少钱台州网站优化公司
  • 专业的高端网站制作公司国内建站平台有哪些
  • 雨花区最新情况官网seo
  • 大连九死一疯事件深圳关键词优化软件
  • 北京网站建设认宁波优化系统
  • 做第三方网站注意什么意思谷歌seo是什么职业
  • 久久建筑网碗扣式钢管脚手架安全技术规范seo优化内页排名
  • 股票网站建设西安网站建设
  • 怎么敲代码做网站自己怎么优化网站排名
  • 聊城网站建设推广推广服务商
  • 网站优化排名分享隐迅推互联网营销师有什么用
  • 济阳县做网站公司关键词查找
  • 太原模板建站平台营销培训课程有哪些
  • 淮安做网站.卓越凯欣鹤壁网络推广哪家好
  • 淘宝网站建设策划案找代写文章写手