![](https://img-blog.csdnimg.cn/20201014180756930.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
ORACLE
ghvbngf
这个作者很懒,什么都没留下…
展开
-
row_number()over(partition by col1 order by col2)
OVER(PARTITION BY)函数介绍开窗函数 Oracle从8.1.6开始提供分析函数,分析函数用于计算基于组的某种聚合值,它和聚合函数的不同之处是:对于每个组返回多行,而聚合函数对于每个组只返回一行。 开窗函数指定了分析函数工作的数据窗口大小,这个数据窗口大小可能会随着行的变化而变化,举例如下:1:over后的转载 2013-12-17 16:32:22 · 1581 阅读 · 0 评论 -
oracle case when的用法
select distinct(lot_code) lotcode,count(distinct(issue_id)) issuecount, sum(case when total_amount = total_amount then total_amount else 0 end) sellcount, sum(case when handle_status=3原创 2014-04-02 14:37:06 · 700 阅读 · 0 评论