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, 2430🔥, 0💬
Popular Posts:
What Are Date and Time Functions in MySQL? MySQL offers a number of functions for date and time valu...
How To Convert a Unicode Strings to Non-Unicode Strings in SQL Server Transact-SQL? Since Unicode ch...
How To Drop a Stored Procedure in Oracle? If there is an existing stored procedure and you don't wan...
What Is an Oracle Tablespace in Oracle? An Oracle tablespace is a big unit of logical storage in an ...
How To Start Instance with a Minimal Initialization Parameter File in Oracle? The sample initializat...