PostgreSQL Summary Stats and Window Functions
Learn how to create queries for analytics and data engineering with window functions, the SQL secret weapon!
Comece O Curso Gratuitamente4 Horas12 Videos44 Exercicios
Create Your Free Account
or
By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.Treinar 2 ou mais pessoas?Experimente o DataCamp For Business
Loved by learners at thousands of companies
Descrição do Curso
Have you ever wondered how data professionals use SQL to solve real-world business problems, like generating rankings, calculating moving averages and running totals, deduplicating data, or performing time intelligence? If you already know how to select, filter, order, join and group data with SQL, this course is your next step. By the end, you will be writing queries like a pro! You will learn how to create queries for analytics and data engineering with window functions, the SQL secret weapon! Using flights data, you will discover how simple it is to use window functions, and how flexible and efficient they are.
Para Empresas
Treinar 2 ou mais pessoas?
Obtenha acesso à biblioteca completa do DataCamp, com relatórios, atribuições, projetos e muito mais centralizadosNas seguintes faixas
- 1
Introduction to window functions
GrátisIn this chapter, you'll learn what window functions are, and the two basic window function subclauses, ORDER BY and PARTITION BY.
Introduction50 xpWindow functions vs GROUP BY50 xpNumbering rows100 xpNumbering Olympic games in ascending order100 xpORDER BY50 xpNumbering Olympic games in descending order100 xpNumbering Olympic athletes by medals earned100 xpReigning weightlifting champions100 xpPARTITION BY50 xpReigning champions by gender100 xpReigning champions by gender and event100 xpRow numbers with partitioning50 xp - 2
Fetching, ranking, and paging
In this chapter, you'll learn three practical applications of window functions: fetching values from different parts of the table, ranking rows according to their values, and binning rows into different tables.
- 3
Aggregate window functions and frames
In this chapter, you'll learn how to use aggregate functions you're familiar with, like `AVG()` and `SUM()`, as window functions, as well as how to define frames to change a window function's output.
Aggregate window functions50 xpRunning totals of athlete medals100 xpMaximum country medals by year100 xpMinimum country medals by year100 xpFrames50 xpNumber of rows in a frame50 xpMoving maximum of Scandinavian athletes' medals100 xpMoving maximum of Chinese athletes' medals100 xpMoving averages and totals50 xpMoving average's frame50 xpMoving average of Russian medals100 xpMoving total of countries' medals100 xp - 4
Beyond window functions
In this last chapter, you'll learn some techniques and functions that are useful when used together with window functions.
Para Empresas
Treinar 2 ou mais pessoas?
Obtenha acesso à biblioteca completa do DataCamp, com relatórios, atribuições, projetos e muito mais centralizadosNas seguintes faixas
Michel Semaan
Veja MaisData Scientist
Fernando Gonzalez Prada
Veja MaisData Science Consultant
O que os outros alunos têm a dizer?
Cadastre-se mais 13 milhões de alunos e comece PostgreSQL Summary Stats and Window Functions Hoje!
Create Your Free Account
or
By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.