DEV Community

AsadullohRuziev
AsadullohRuziev

Posted on • Edited on

PostgreSQL unit-10

Aggregate Functions

Fake data mockaroo.com/
Image description

Image description

\i C:/Users/asadu/Downloads/car.sql;
Enter fullscreen mode Exit fullscreen mode

Image description

Image description

SELECT MAX(price) FROM car;
Enter fullscreen mode Exit fullscreen mode
SELECT MIN(price) FROM car;
Enter fullscreen mode Exit fullscreen mode
SELECT AVG(price) FROM car;
Enter fullscreen mode Exit fullscreen mode
 SELECT ROUND(AVG(price)) FROM car;
Enter fullscreen mode Exit fullscreen mode

Image description

-----------------------------------------

Image description

Image description

Image description

Top comments (0)