Interactive Course
In this online course, you will master PostgreSQL recursive queries, also known as WITH clauses, and common table expressions (CTEs).
Ultimate money saver
With our Forever plan this course will cost you only
$ 3.78
87% OFF
39 hours left
This online course is intended for intermediate users and will benefit beginner data analysts, IT students, business developers, and more. The prerequisite is understanding the basics of SQL presented in our SQL Basics in PostgreSQL course followed by some practice.
Recursive queries are often called WITH clauses and are essentially just named subqueries. It is a fairly new feature of SQL that allows you to manage a long query and break it into smaller, more readable chunks. Unlike SQL subqueries, recursive queries allow the traversal of hierarchical models with enormous depth. Using recursive queries, you can process hierarchical structures, such as graphs and trees; for example, you can find the shortest path between two cities using a railway network or the length of the "chain of command" from a regular employee to the CEO.
In this online course, you will learn simple, common table expressions (CTEs), nested CTEs, and recursive CTEs. You will also discover how to manage a PostgreSQL query with a CTE, when to nest CTEs, and how to use recursive CTEs to move through hierarchical data models.
Course progress
Exercises completed
Test your knowledge of PostgreSQL
Exercises completed
Your first encounter with Common Table Expressions
Exercises completed
You'll get to know how to use nested CTEs
Exercises completed
You'll find out what recursion is and how to use it in SQL queries
Exercises completed
You'll learn how to use INSERT, DELETE, and UPDATE statements with CTEs.
Exercises completed
Test your knowledge in this final quiz.
Exercises completed