Technical requirements
The examples used in this chapter are designed for use on SQL Server 2022 and Azure SQL Database, but they should work on versions of SQL Server 2012 and later. The Developer Edition of SQL Server is free for development environments and can be used to run all the code samples. There is also a free tier of Azure SQL Database you can use for testing at https://aka.ms/freedb.
You will need the sample databases AdventureWorks2016_EXT
(referred to as AdventureWorks
) and AdventureWorksDW2016_EXT
(referred to as AdventureWorksDW
), which can be found on GitHub at https://github.com/Microsoft/sql-server-samples/releases/tag/adventureworks. The code used in this chapter can also be found on GitHub at https://github.com/PacktPublishing/Learn-T-SQL-Querying-Second-Edition/tree/main/ch6.