Counting, Grouping and Paging

COUNT, SUM and AVG let the database add up rows instead of sending every one to Python, GROUP BY gives one answer for each vendor, and LIMIT with OFFSET hands an API one page of a long list at a time, with COUNT(*) giving the total beside it.

By

Updated

Cheat sheet: Counting, Grouping and Paging
Category
FastAPI
Level
Journeyman
Tags
Aggregate Function, COUNT, database, group by, having, OFFSET Clause, Pagination, sql, sqlite