Collections:
Use Group Functions in the SELECT Clause in Oracle
How To Use Group Functions in the SELECT Clause in Oracle?
✍: FYIcenter.com
If group functions are used in the SELECT clause, they will be used on the rows that meet the query selection criteria, the output of group functions will be returned as output of the query. The following select statement returns 4 values calculate by 4 group functions on all rows of the "departments" table:
SQL> SELECT COUNT(*), MIN(department_id),
2 MAX(department_id) FROM departments;
COUNT(*) MIN(DEPARTMENT_ID) MAX(DEPARTMENT_ID)
---------- ------------------ ------------------
27 10 270
⇒ Group Functions Used with Non-group Selection Fields in Oracle
⇐ What Are Group Functions in Oracle
2019-11-21, 2345🔥, 0💬
Popular Posts:
How To Install PHP on Windows in MySQL? The best way to download and install PHP on Windows systems ...
How To Create a Table Index in Oracle? If you have a table with a lots of rows, and you know that on...
How To Provide Default Values to Function Parameters in SQL Server Transact-SQL? If you add a parame...
How To Divide Query Output into Multiple Groups with the GROUP BY Clause in SQL Server? Sometimes, y...
How To Query Tables and Loop through the Returning Rows in MySQL? The best way to query tables and l...