Introduction
The very basics
Infinite looping
Processing trees with recursive CTEs
18. Hierarchical company 1/3
Processing graphs with recursive ctes
Summary

Instruction

Quite impressive, right? We'll now help you construct the query step-by-step, so you understand how it works.

Exercise

In the first step, we'll show information about the boss. This is the only person in the table that has a NULL SuperiorId. For that person, show the Id, FirstName, LastName, SuperiorId, and a final column called Path with N'Boss' inside.

Stuck? Here's a hint!

Remember that you can check whether a value is NULL using:

WHERE ColumnName IS NULL