当前位置:网站首页>Data query language (DQL)
Data query language (DQL)
2022-07-01 18:17:00 【Born like summer flowers LXM】
DQL Three ways to query

1. Basic query
(1) Query all










(2) Query some fields

(3) Column alias

(4) Restrict queries




(5) Go to check again


(6)where Clause

(7) Relational operator ( Greater than or equal to )


(8) Logical operators ( And or not )


(9) Continuous interval query (between…and…)


(10)in and not in


(11)is null



(12) Fuzzy query


(13) Merge query








(14) Sort


(15) Aggregate functions ( Count 、 Sum up 、 Average 、 Maximum 、 Minimum )



Count



Sum up

Average

minimum value

Maximum

(16) Group query





having Clause


2. Relational query



(1) Internal connection



inner join Is a column connection
union Is row connection 
Equivalent connection







Non equivalent connection








(2) External connection

External connection : Left connection














External connection : The right connection






(3) Full connection








(4) Cross connect








Another way is to find 16 Two ways of combination 


Another way 
3. nested subqueries

The order of inquiry 

(1) Scalar subquery



(2) Column query



(3) Line sub query




(4) Table sub query





4. Subquery exercise
Case study 1



Case study 2





Case study 3





Case study 4




5. practice
























边栏推荐
- Redis -- data type and operation
- Detailed explanation of select in golang
- Nielseniq found that 60% of the re launched products had poor returns
- At present, where is the most formal and safe account opening for futures speculation? How to open a futures account?
- 网上股票开户安全吗?是否可靠?
- 2022 Heilongjiang latest fire protection facility operator simulation test question bank and answers
- EasyCVR通过国标GB28181协议接入设备,出现设备自动拉流是什么原因?
- Android development interview was badly hit in 3 years, and now the recruitment technical requirements are so high?
- 手机开户股票开户安全吗?那么开户需要带些什么?
- Kernel stray cat stray dog pet adoption platform H5 source code
猜你喜欢
![[splishsplash] about how to receive / display user parameters, MVC mode and genparam on GUI and JSON](/img/83/9bd9ce7608ebfe7207ac008b9e8ab1.png)
[splishsplash] about how to receive / display user parameters, MVC mode and genparam on GUI and JSON

Cloud picture says | distributed transaction management DTM: the little helper behind "buy buy buy"

New 95 community system whole station source code
![[PHP foundation] realize the connection between PHP and SQL database](/img/eb/c8953eddfe3b19b0adb5529957d275.jpg)
[PHP foundation] realize the connection between PHP and SQL database

transform. Forward and vector3 Differences in the use of forward

Rotation order and universal lock of unity panel

Samba basic usage

Definition of rotation axis in mujoco

Explain in detail the process of realizing Chinese text classification by CNN

SQL injection vulnerability (MySQL and MSSQL features)
随机推荐
Sword finger offer II 105 Maximum area of the island
Blackwich: the roadmap of decarbonization is the first step to realize the equitable energy transformation in Asia
Batch export all pictures in PPT in one second
聊聊项目经理最爱使用的工具
APK签名流程介绍[通俗易懂]
Penetration practice vulnhub range Tornado
MySQL + JSON = King fried
What are the six steps of the software development process? How to draw software development flow chart?
Zabbix报警执行远程命令
JS how to convert a string with a delimiter into an n-dimensional array
ISO 27001 Information Security Management System Certification
Leetcode problem solving series -- continuous positive sequence with sum as s (sliding window)
传感器尺寸、像素、DPI分辨率、英寸、毫米的关系
JDBC: deep understanding of Preparedstatement and statement[easy to understand]
Kernel stray cat stray dog pet adoption platform H5 source code
徽商期货是正规期货平台吗?在徽商期货开户安全吗?
Data warehouse (3) star model and dimension modeling of data warehouse modeling
The difference and relationship between iteratible objects, iterators and generators
Cloud picture says | distributed transaction management DTM: the little helper behind "buy buy buy"
MySQL -- explain performance optimization