Welcome Back

Google icon Sign in with Google
OR
I agree to abide by Pharmadaily Terms of Service and its Privacy Policy

Create Account

Google icon Sign up with Google
OR
By signing up, you agree to our Terms of Service and Privacy Policy
Instagram
youtube
Facebook

Find the Average Price of All Products in SQL

Find the Average Price of All Products in SQL


producs Table:

Query Explanation:
● SELECT AVG(Price) AS AveragePrice
 Calculates the average value of the Price column and labels the result as AveragePrice.

● FROM Products
 Retrieves data from the Products table where prices of all products are stored.

 

SQL Query:

USE SalesInventoryDB;

select * from products;
select avg(UnitPrice) as AveragePrice
from products

 

Output: