If you want to calculate average value of any column in the table then you use average function
syntax:
select avg( price) as avg price from products;
when you run the above command sql will return the average price of the price in the products table
syntax:
select avg( price) as avg price from products;
when you run the above command sql will return the average price of the price in the products table
No comments:
Post a Comment