Udemy
    •  
    •  
    •  
    •  
    •  
    •  
    •  
    •  
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
EssentialSQL: SQL Window Functions for Business Analytics
Highest Rated
Rating: 4.5 out of 5(115 ratings)
552 students

EssentialSQL: SQL Window Functions for Business Analytics

SQL Window Functions for SQL Server, MySQL, SQLite & PostgreSQL, for Data Analysis, Business Analytics and Intelligence
Last updated 2/2024
English

What you'll learn

  • Learn how to incorporate window functions into your SQL queries.
  • Understand how partitions and windows work together within a query.
  • Apply window functions so you can avoid using cursors in your SQL.
  • Understand the difference between window function mechanics and GROUB BY summaries.
  • Create complex queries involving joins using window functions.
  • Apply aggregate, analytic, and ranking functions to perform common business tasks such as calculating running totals or comparing one row’s value to the next.
  • Create queries using either MySQL, PostgreSQL, or SQL Server.

Coding Exercises

This course includes our updated coding exercises so you can practice your skills as you learn.

See a demo
Image of coding exercise example

Course content

9 sections41 lectures3h 38m total length
  • Welcome to the Course2:22
  • Why You Should Learn Windows Functions3:33

    One good question to ask yourself is why use Window functions?  In this video I want to quickly show you how to calculate a running total using a using a subquery versus a window function.  I think you'll see it is much easier to do so using the window function.

  • What Flavor of SQL Should I Choose?5:03
  • How to Take the Course4:11
  • Tools Used and Database Setup6:38

Requirements

  • You should already be familiar with SELECT, GROUP BY, and ORDER BY clauses
  • Knowledge of joins and subqueries isn't required, but recommended.
  • If you can write a simple GROUP BY statement with HAVING, then you are ready for this course.
  • No special equipment needed, all exercises are done online.
  • Optional: Install a MySQL, PostgreSQL, or SQL Server learning lab on your own computer.

Description

In this Course you will Learn to:

  • Write simpler queries using window functions.

  • Know how window functions work with partition and other clauses to help you form running totals or compare values from one row to the next.

  • Create complex queries involving joins using window functions.

  • Learn how to use LEAD and LAG to avoid using cursors in your SQL scripts.

  • Write window functions using MySQL, PostgreSQL, SQLite, or SQL Server – your choice!  I'm sure they will work with Oracle, I just haven't tested...  :)

  • Understand how to set up a window frame and their affect on the window function.

  • Know the difference between window functions and classing GROUP BY results.

  • Work with multiple window functions within a query.

  • Who to use results from a window functions within the same query.

  • Learn to us the three classes of functions: Aggregate, Ranking, and Analytic functions.

Nothing is worse than

  • Being excited to learn something new but not knowing where to start.

  • Wasting time learning the wrong features.

  • You being overwhelmed with options and not knowing which to use.

Imagine Having...

  • Knowledge - Knowing how to quickly use window functions to take your SQL to the next level.

  • Confidence - Feeling good that you’re on the right track.

  • Accomplishment - Having a sense of accomplishment that you've learned something most cannot.


By the time you’ve completed this course you’ll have an appreciation of window functions, overcome your fear, and able to use them to simplify some of your very complex queries.

Who this course is for:

  • Advanced Beginner to Intermediate SQL query authors curious about window functions.
  • If you're having a hard time understanding the ins and outs of window functions, then this course is for you as I explain it to you in simple to understand English.
  • Business analysts looking more ways to write queries.
  • Data Engineers needing more tools to deal with dirty data, such as an easy means to deduplicate incoming rows.
  • Recent college graduates looking to hone their SQL skills.
  • Job applicants looking for that extra edge with their next interview!