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

推荐订阅源

WordPress大学
WordPress大学
Engineering at Meta
Engineering at Meta
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
Martin Fowler
Martin Fowler
雷峰网
雷峰网
Recent Announcements
Recent Announcements
博客园 - 叶小钗
F
Full Disclosure
C
Check Point Blog
A
About on SuperTechFans
L
LangChain Blog
Vercel News
Vercel News
T
The Blog of Author Tim Ferriss
博客园 - 司徒正美
C
Cybersecurity and Infrastructure Security Agency CISA
C
CXSECURITY Database RSS Feed - CXSecurity.com
Cisco Talos Blog
Cisco Talos Blog
Hugging Face - Blog
Hugging Face - Blog
Recorded Future
Recorded Future
MongoDB | Blog
MongoDB | Blog
Project Zero
Project Zero
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
D
Darknet – Hacking Tools, Hacker News & Cyber Security
Know Your Adversary
Know Your Adversary
D
Docker
U
Unit 42
酷 壳 – CoolShell
酷 壳 – CoolShell
T
The Exploit Database - CXSecurity.com
L
Lohrmann on Cybersecurity
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Latest news
Latest news
V
Visual Studio Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
L
LINUX DO - 最新话题
Google DeepMind News
Google DeepMind News
小众软件
小众软件
NISL@THU
NISL@THU
GbyAI
GbyAI
H
Heimdal Security Blog
Jina AI
Jina AI
I
InfoQ
PCI Perspectives
PCI Perspectives
P
Privacy International News Feed
P
Proofpoint News Feed
N
News and Events Feed by Topic
C
CERT Recently Published Vulnerability Notes
aimingoo的专栏
aimingoo的专栏
SecWiki News
SecWiki News
B
Blog RSS Feed
阮一峰的网络日志
阮一峰的网络日志

博客园 - 大汪的数据之路

星环大数据使用体验 vibe coding使用体验 基于SQL实现分组的文字排序聚合 数据码农马年大吉 字符串分割并展开成表格的SQL实现方法 BI报表及可视化分析类工具使用经验总结(下) BI报表及可视化分析类工具使用经验总结(上) 基于Python实现自动化微信通知和预警 Chat2DB测试体验 常用数据管理工具与平台汇总 OneID系统建设实践总结 网易有数BI使用总结 网易NDH大数据平台使用经验 版本管理总结 程序自动化vs人工手动处理 SQL开发总结 数据平台使用经验 数据团队运维值班任务简介 Python环境安装、管理与部署 windows获取kerberos认证 SQL动态长度行列转置 ODI Scenario 场景
Oracle KEEP 分析函数
大汪的数据之路 · 2017-12-03 · via 博客园 - 大汪的数据之路

Oracle中为了解决子集合中查询最值的问题,提出了KEEP()语法。

典型案列如:在每个部门中找出年龄最小的人中的最高工资。

基本语法结构:

MAX(COL2) KEEP (DENSE_RANK FIRST/LAST ORDER BY COL1) PARTITION BY()

http://blog.csdn.net/hustzw07/article/details/51190201

拓展:

查找年龄最小工资最高的人:

方法:使用First_value函数就可以。 FIRST_VALUE(EMPLOYEE_ID) OVER(PARTITION BY DEPARTMENT ORDER BY AGE, SALARY DESC)