HOME | PHP Tutorial | CSS
facebook icon
AgerNic.com
WEB DEVELOPER SITE, HTML, CSS, PHP
HTML Tutorial

CSS Tutorial

SQL COUNT(), AVG() and SUM() Functions


The COUNT() function returns the number of rows that matches a specified criteria.
The AVG() function returns the average value of a numeric column.
The SUM() function returns the total sum of a numeric column.

SQL COUNT(), AVG() and SUM() Functions - how to create - example


COUNT() Syntax

Example 1: COUNT() Syntax
SELECT COUNT(column_name)
FROM table_name
WHERE condition;


AVG() Syntax

Example 2: AVG() Syntax
SELECT AVG(column_name)
FROM table_name
WHERE condition;


SUM() Syntax

Example 3: SUM() Syntax
SELECT SUM(column_name)
FROM table_name
WHERE condition;

sql count avg and sum functions SQL COUNT(), AVG() and SUM() Functions - sql tutorial

2578. SQL LIKE - SQL Tutorial

http://www.sql-tutorial.net/SQL-LIKE.asp

48. SQL Tutorial - An Ultimate Guide for Beginners
SQL Tutorials for Beginners - Learn the concepts of world
https://www.tutorialrepublic.com/sql-tutorial/

3283. Insert into SQL - Insert into table SQL - Insert data in sql, sql tutorial
Insert into SQL - Insert into table SQL - Insert data in sql sql tutorial
https://www.agernic.com/sql-tutorial/insert-into-sql-insert-into-table-sql-data-in-sql.html

2564. SQL AND & OR - SQL Tutorial

http://www.sql-tutorial.net/SQL-AND-OR.asp

2562. Link to SQL Tutorial - SQL Tutorial

http://www.sql-tutorial.net/link-to-SQL-Tutorial.asp

881. MySQL Tutorial
MySQL Tutorial for Beginners - Learn MySQL in simple and easy steps starting from basic to advanced concepts with examples including database programming clauses command functions administration queries and usage along with PHP in simple steps. This tuto
https://www.tutorialspoint.com/mysql/index.htm

Your add here
How to get PHP errors to display?
How to prevent sql injection in php mysqli
How do I get PHP errors to display - PHP error_reporting()
mysql_query(): The mysql extension is deprecated and will be removed i
Function eregi_replace() is deprecated in php - How to fix
PHP delete an element from an array
Uncaught Error: Call to undefined function MYSQL_NUM_ROWS() in
Deprecated: mysql_connect() mysql extension is deprecated and will be
mysqli_fetch_array() expects parameter 1 to be mysqli_result boolean g
SQL IN Operator - example
SQL BETWEEN Operator
SQL like syntax and example
SQL WHERE AND & OR multiple conditions
SQL create table primary key autoincrement
PHP mysqli_connect () Function
SQL COUNT(), AVG() and SUM() Functions
Display data from SQL database with MySQLi into php - html table
SQL CREATE DATABASE - example
SQL mysql order by columns, by date, by asc, by desc, random with PHP
PHP mysqli_query() Function - mysqli query
SQL delete row - SQL delete table
SQL update - SQL update select
Insert into SQL - Insert into table SQL - Insert data in sql
Login in PHP - simple login script with PHP MYSQL