当前位置:网站首页>Advanced learning of MySQL -- basics -- multi table query -- self join
Advanced learning of MySQL -- basics -- multi table query -- self join
2022-07-07 00:34:00 【Magic pig 9898】
grammar :
Self connection can be internal connection or external connection
for example
Query employees , And the name of its leader
select a.name , b.name from emp a , emp b where a.managerid = b.id;
in other words , If an employee doesn't have a leader , This employee will not be found out , Isn't that the inner connection
Another example is
Query all employees , And its subordinate leaders , If the employee has no leader , We need to find out
select a.name , b.name from emp a left outer join emp b on a.managerid = b.id;
边栏推荐
- QT tutorial: creating the first QT program
- Compilation of kickstart file
- File and image comparison tool kaleidoscope latest download
- What can the interactive slide screen demonstration bring to the enterprise exhibition hall
- iMeta | 华南农大陈程杰/夏瑞等发布TBtools构造Circos图的简单方法
- Mujoco finite state machine and trajectory tracking
- JWT signature does not match locally computed signature. JWT validity cannot be asserted and should
- 刘永鑫报告|微生物组数据分析与科学传播(晚7点半)
- Use package FY in Oracle_ Recover_ Data. PCK to recover the table of truncate misoperation
- Lombok 同时使⽤ @Data 和 @Builder 的坑,你中招没?
猜你喜欢

Jenkins' user credentials plug-in installation

System activity monitor ISTAT menus 6.61 (1185) Chinese repair

Introduction to GPIO

48页数字政府智慧政务一网通办解决方案

DAY FIVE

Understand the misunderstanding of programmers: Chinese programmers in the eyes of Western programmers

Everyone is always talking about EQ, so what is EQ?

【vulnhub】presidential1

On February 19, 2021ccf award ceremony will be held, "why in Hengdian?"

2022年PMP项目管理考试敏捷知识点(9)
随机推荐
一图看懂对程序员的误解:西方程序员眼中的中国程序员
GPIO简介
Leecode brush questions record sword finger offer 43 The number of occurrences of 1 in integers 1 to n
[boutique] Pinia Persistence Based on the plug-in Pinia plugin persist
js导入excel&导出excel
Introduction au GPIO
St table
Notes of training courses selected by Massey school
Use Yum or up2date to install the postgresql13.3 database
GEO数据挖掘(三)使用DAVID数据库进行GO、KEGG富集分析
TypeScript增量编译
PostgreSQL uses pgpool II to realize read-write separation + load balancing
[vector retrieval research series] product introduction
[CVPR 2022] target detection sota:dino: Detr with improved detecting anchor boxes for end to end object detection
Model-Free Prediction
How can computers ensure data security in the quantum era? The United States announced four alternative encryption algorithms
Win10 startup error, press F9 to enter how to repair?
Supersocket 1.6 creates a simple socket server with message length in the header
Pytest multi process / multi thread execution test case
MIT 6.824 - raft Student Guide