惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

GbyAI
GbyAI
T
Tenable Blog
Webroot Blog
Webroot Blog
L
Lohrmann on Cybersecurity
S
Securelist
S
Schneier on Security
NISL@THU
NISL@THU
Know Your Adversary
Know Your Adversary
C
Cybersecurity and Infrastructure Security Agency CISA
T
The Exploit Database - CXSecurity.com
L
LINUX DO - 热门话题
C
CXSECURITY Database RSS Feed - CXSecurity.com
O
OpenAI News
I
Intezer
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
TaoSecurity Blog
TaoSecurity Blog
S
Secure Thoughts
Application and Cybersecurity Blog
Application and Cybersecurity Blog
P
Privacy International News Feed
H
Hacker News: Front Page
N
Netflix TechBlog - Medium
M
MIT News - Artificial intelligence
博客园 - Franky
PCI Perspectives
PCI Perspectives
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Microsoft Azure Blog
Microsoft Azure Blog
MongoDB | Blog
MongoDB | Blog
L
LangChain Blog
P
Proofpoint News Feed
S
Security Affairs
WordPress大学
WordPress大学
The Last Watchdog
The Last Watchdog
S
SegmentFault 最新的问题
小众软件
小众软件
F
Full Disclosure
博客园 - 叶小钗
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
T
The Blog of Author Tim Ferriss
Simon Willison's Weblog
Simon Willison's Weblog
P
Palo Alto Networks Blog
Security Latest
Security Latest
P
Proofpoint News Feed
月光博客
月光博客
T
Tailwind CSS Blog
Scott Helme
Scott Helme
Hacker News - Newest:
Hacker News - Newest: "LLM"
Google Online Security Blog
Google Online Security Blog
T
Threat Research - Cisco Blogs
Help Net Security
Help Net Security
Project Zero
Project Zero

博客园 - Burt

软件项目研发的设计流程 访问IIS元数据库失败解决方法(转) 经典SQL语句大全 js 比较2日期大小 - Burt - 博客园 合并表格,并实现对datatable的group by 功能 - Burt 时间段查询 sql 日期格式转换(convert用法)(转) 分页存储过程 刷新后保持页面滚动条位置C#&VB(转) - Burt - 博客园 Dropdownlist样式设置 - Burt - 博客园 TreeView的遍历(转) 读取天气预报所产生乱码解决方法MiniSite.Weather.print("Wealth") 40种网页常用小技巧(javascript) 页面图象鼠标操作放大和制作图片热点 无法将类型login_aspx转换为System.Web.UI.WebControl c# 发邮件(转摘) [没有相关源的行] 访问被拒绝 水晶报表制作 页面自动刷新以及广告程序得Javascript代码
left join on
Burt · 2009-06-18 · via 博客园 - Burt

问题:
select * from A left join  f on e.cust=f.account_id where f.status='0'

select * from A left join  f on e.cust=f.account_id and f.status='0'
的区别
在做外连查询的时候ON里面的条件是在外连执行之前筛选的的
where后的查询条件在外联之后执行
上面哪个是左联后!再选出f.status='0'的,等于在两个表连接 了以后 再去 做过滤
WHERE哪个说白了就是连主表都砍掉的, 结果集里只存在f.status='0'的结果

on 里的条件是先执行的 ,如果是and ,就可以认为是on的条件先执行,
不用在连接之后再去过滤 
left join  f on e.cust=f.account_id and f.status='0'
这个语句会把两个表的数据都列出来
不过f这个表的数据并不会全部列出,只会列出f表的 f.status='0' 的数据