Get the App
SLTechnology News&Howtos  ›  Database  › 

What is the function of the RATIO_TO_REPORT () OVER () function in Oracle

Shulou Source: shulou.com Published: 2022-05-31 21:48:34 09月30日 Update

This article will explain in detail what is the function of the RATIO_TO_REPORT () OVER () function in Oracle. The content of the article is of high quality, so the editor shares it for you to do a reference. I hope you will have a certain understanding of the relevant knowledge after reading this article.

20:00:24 SYS@orcl > conn scott/tiger;Connected.20:00:30 SCOTT@orcl > create table test20:01:22 2 (20:01:22 3 name varchar (20), 20:01:22 4 kemu varchar (20), 20:01:22 5 score number20:01:22 6); Table created.Elapsed: 0000 kemu varchar 00.0420 create table test20:01:22 23 SCOTT@orcl > insert into test values ('testa','yuwen',10) 1 row created.Elapsed: 00 row created.Elapsed 0020 00.0220 testa',' 35 SCOTT@orcl > insert into test values ('testb','yuwen',120); 1 row created.Elapsed: 00 testb','yuwen',120 00.0120 SCOTT@orcl 0136 SCOTT@orcl > insert into test values 1 row created.Elapsed: 00 row created.Elapsed 0020 00.0020 insert into test values 36 SCOTT@orcl > row created.Elapsed ('testc','yuwen',40) Commit complete.Elapsed: 00 score,20:03:32 0020 00.0020 over 01 over 42 SCOTT@orcl > select name,20:03:32 2 score,20:03:32 3 ratio_to_report (score) over () as ratio1,20:03:32 4 ratio_to_report (score) as ratio220:03:32 5 from test NAME SCORE RATIO1 RATIO2--testa 10. 03030303 .043478261testb 60. 181818182 .260869565 testc 40. 121212121. 173913043 testb 120.363636364. 52173913testa 100.3030303 1Elapsed: 00:00 : 00.0020 OVER 03 SCOTT@orcl > that's all about what the function of the RATIO_TO_REPORT () OVER () function in Oracle is. I hope the above content can be of some help to you and learn more knowledge. If you think the article is good, you can share it for more people to see.

Tags: Function function content article more knowledge article good quality English reference help related Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Docker Xiaomi Huawei MySQL Microsoft