当前位置:网站首页>MySQL数据库 - 单表查询(三)
MySQL数据库 - 单表查询(三)
2022-04-23 19:28:00 【x 心 动】
第1关:对查询结果进行排序
USE School;
#请在此处添加实现代码
########## Begin ##########
########## 查询1班同学的所有信息以成绩降序的方式显示结果 ##########
select * from tb_score where class_id=1 order by score desc;
########## End ##########
第2关:分组查询
USE School;
#请在此处添加实现代码
########## Begin ##########
########## 对班级名称进行分组查询 ##########
select * from tb_class group by class_id;
########## End ##########
第3关:使用 LIMIT 限制查询结果的数量
USE School;
#请在此处添加实现代码
########## Begin ##########
########## 查询班级中第2名到第5名的学生信息 ##########
select * from tb_score order by score desc limit 1,4;
########## End ##########
版权声明
本文为[x 心 动]所创,转载请带上原文链接,感谢
https://blog.csdn.net/qq_45623072/article/details/124055804
边栏推荐
- Solve the problem of invalid listview Click
- Is meituan, a profit-making company with zero foundation, hungry? Coupon CPS applet (with source code)
- 指针数组与数组指针的区分
- Openlayers 5.0 reload the map when the map container size changes
- Core concepts of rest
- NiO related Basics
- C学习完结
- Codeforces Round #783 (Div. 2) D题解
- 【h264】libvlc 老版本的 hevc h264 解析,帧率设定
- Coordinate conversion WGS-84 to gcj-02 and gcj-02 to WGS-84
猜你喜欢
Lottery applet, mother no longer have to worry about who does the dishes (assign tasks), so easy
Common SQL commands
OpenHarmony开源开发者成长计划,寻找改变世界的开源新生力!
Why is PostgreSQL about to surpass SQL Server?
MFCC: Mel频率倒谱系数计算感知频率和实际频率转换
On the forced conversion of C language pointer
Kubernetes入门到精通-裸机LoadBalence 80 443 端口暴露注意事项
The platinum library cannot search the debug process records of some projection devices
The most detailed network counting experiment in history (2) -- rip experiment of layer 3 switch
Command - sudo
随机推荐
A brief explanation of golang's keyword "competence"
PostgreSQL
Core concepts of rest
openlayers 5.0 两种居中方式
SQL Server database in clause and exists clause conversion
How to uninstall easyton
点云数据集常用处理
Easy mock local deployment (you need to experience three times in a crowded time. Li Zao will do the same as me. Love is like a festival mock)
Common processing of point cloud dataset
First experience of using fluent canvas
坐标转换WGS-84 转 GCJ-02 和 GCJ-02转WGS-84
【h264】libvlc 老版本的 hevc h264 解析,帧率设定
Use of fluent custom fonts and pictures
On the forced conversion of C language pointer
JS calculation time difference
MySQL lock
Zero base to build profit taking away CPS platform official account
SSDB Foundation
Openlayers 5.0 discrete aggregation points
An algorithm problem was encountered during the interview_ Find the mirrored word pairs in the dictionary