当前位置:网站首页>Sorting out common SQL interview questions and answers
Sorting out common SQL interview questions and answers
2022-07-23 11:14:00 【I'm a girl, I don't program yuan】
List of articles
How to optimize massive data SQL
According to the execution plan (explain) Set the appropriate index , Choose the right one type(system best ,all The worst )
Database storage location
The data files and indexes of the database are stored in disk in ;
Each time you search for data, you need to read the index file to Memory in
MySQL And hive
OLAP: On line analytical processing , Corresponding data warehouse hive, Large amount of data , Not for efficiency
OLTP: Online data processing , Corresponding database , The amount of data is small , Pursuing efficiency
Aggregate functions and group by Field restrictions for simultaneous use
select Field , Aggregate functions
from Table name
where Conditions
group by Field
here select The fields of are either contained in the aggregate function , Or included in group by in , Otherwise it will go wrong .
Nested use of aggregate functions
Aggregate functions cannot be nested directly , But you can nest subqueries that contain aggregate functions .
error :
select max(count(*)) from ...
correct :
select max(cnt) from(
select count(*) as cnt from...
)
边栏推荐
- Flask源码剖析(一)请求入口
- 讲师征集令 | Apache DolphinScheduler Meetup分享嘉宾,期待你的议题和声音!
- 使用pytorch实现基于VGG 19预训练模型的鲜花识别分类器,准确度达到97%
- 视图集及路由
- 对NLP中transformer里面decoder的理解
- 8. Surface geometry
- Master slave synchronization step read / write separation + self encountered error sharing
- 2. Analysis of the return value of the startup function
- 使用cmd安装pygame
- Data Lake: introduction to delta Lake
猜你喜欢

FFmpeg 音频编码

Web server failed to start. Port 8080 was already in use.

pygame实现飞机大战游戏

从零开始的pytorch小白使用指北

With only 5000 lines of code, AI renders 100 million landscape paintings on v853

Web server failed to start. Port 8080 was already in use.
![[Doris]配置和基本使用contens系统(有时间继续补充内容)](/img/74/21c5c0866ed6b1bb6f9a1e3755b61e.png)
[Doris]配置和基本使用contens系统(有时间继续补充内容)

好玩的代码雨,在线分享给大家~-

使用cmd安装pygame

Spark常见面试问题整理
随机推荐
【Pyradiomics】提取的影像组学特征值不正常(很多0和1)
人脸识别神经网络实现
Data Lake: viewing data lake from data warehouse
使用pytorch实现基于VGG 19预训练模型的鲜花识别分类器,准确度达到97%
[监控部署实操]基于granfana展示Prometheus的图表和loki+promtail的图表
wps中的word中公式复制完后是图片
十年架构五年生活-02第一份工作
ShardingSphere分库分表方案
Master slave synchronization step read / write separation + self encountered error sharing
FFmpeg 音频编码
十年架构五年生活-01毕业之初
【无标题】
6. Barycentric coordinate interpolation and graphics rendering pipeline
排序、限流
分页、过滤
【无标题】
Flask蓝图
Install enterprise pycharm and Anaconda
给图片人脸部分加上马赛克
Spark常见面试问题整理