当前位置:网站首页>SQL left connection, internal connection writing method "recommended collection"
SQL left connection, internal connection writing method "recommended collection"
2022-07-28 23:50:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm your friend, Quan Jun .
The meaning of left connection : Use LEFT JOIN keyword , From The left table Back there to all the lines , Even in Right table There are no matching lines in .
1) Left connection
select a.*, b.*
from table1 a
left join table2 b
on a.id = b.parent_id
2) Internal connection
select a.*, b.*
from table1 a
inner join table2 b
on a.id = b.parent_id
or
select a.*, b.*
from table1 a
join table2 b
on a.id = b.parent_id
Inner connection written inner join or join, No difference
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/128979.html Link to the original text :https://javaforall.cn
边栏推荐
猜你喜欢
Jincang database kingbasees client programming interface guide ODBC (2. Overview)
2022T电梯修理考试试题及模拟考试
Mongodb index add, view, export, delete
使用Pytorch快速训练网络模型
Custom MVC principle and framework
刨根问底学 二叉树
【自】-刷题-峰值
Deep analysis of integrated learning AdaBoost
[self] - question brushing - peak value
利用递归和链表头插法实现链表成组的翻转——LeetCode25 K个一组翻转链表
随机推荐
NPDP考试需要携带什么?文具携带说明
2022焊工(初级)上岗证题目及答案
2022 R2 mobile pressure vessel filling test question simulation test platform operation
MySQL transaction and storage system
Deep analysis of integrated learning xgboost
多传感器融合定位(二)——基于地图的定位
[self] - brush questions array
2022 simulated examination platform operation of hoisting machinery command examination questions
Codeforces Round #810 (Div. 2) A - C
Arm-a53 data "recommended collection"
Merkle tree
【自】-刷题-数组
二舅火了,全网刷屏,他凭什么能治好我的精神内耗?
Zero view h5s video platform getUserInfo information disclosure vulnerability cnvd-2020-67113
2022年G2电站锅炉司炉考试题库模拟考试平台操作
2022-07-28:以下go语言代码输出什么?A:AA;B:AB;C:BA;D:BB。 package main import ( “fmt“ ) func
Pycharm new project
hutool官网(hutool好用吗)
RHCE first day
MySQL introduction