SQL Aggregate function count()

OBJECTIVE

In this chapter you will learn:

About function count ()
Syntax of function count ()
Example of function count ()

 

About function count ()

SQL function count () is used to count the number of values in an expression, either all or distinct. The Count () function can also accept * within parameter but it can only counts the number of rows which is returned by the SQL query.

 

Syntax of function count ()

SELECT * from count (column_name) from table_name
Or

SELECT count (*) from table_name

Example of function count ()

 

 

function count() example
SUMMARY

In this chapter you have learned about SQL function count (). In the next chapter you will learn about SQL function min () so Click on NEXT button to continue learning.


Leave a Reply

Your email address will not be published. Required fields are marked *