《oracle connect by 和 分析函数总结.doc》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、.1.connectby用法总结2一、树查询(递归查询)2二、列转行sys_connect_by_path()32.分析函数总结31.分析函数(OVER)32.分析函数2(Rank,Dense_rank,row_number)33.分析函数3(Top/BottomN、First/Last、NTile)34.窗口函数35.报表函数31...1.connectby用法总结一、树查询(递归查询)1.作用对于oracle进行简单树查询(递归查询)列转行2.基本语法select...from where
7、ll select'广州's,'广东'bfromdual unionall select'衡东's,'衡阳'bfromdual )selectmax(sys_connect_by_path(s,'/'))fromtmp_tabstartwiths='湖南'connectbypriors=b..2.分析函数总结一、统计方面:Sum() Over ([Partition by ] [Order by ])Sum() Over ([Partition by ] [Order by ] Rows Between Precedin
8、g And Following) Sum() Over ([Partition by ] [Order by ] Rows Between Preceding And Current Row)Su