Introduction to CTEs Slides and Sample Queries
Today I am at SQL Saturday Portland Oregon, and at 9:00am I am presenting the Introduction To Common Table Expressions session:
Here is the abstract:
Have you ever wanted to create a recursive query, but didn’t see how to do it. With the Common Table Expressions session you will learn everything needed to start using CTE’s for recursive queries, as temporary views, and to use the result set multiple times in the same query. Learn how simplify query syntax using CTE’s. One of the most overlooked features of SQL Server is the CTE which not only simplifies the query, but gives you the ability to do things that would otherwise be impossible (or at least very challenging) with SQL Server. The class is designed for people who haven’t used CTE’s before, or for those who want to learn the basics of CTEs including data paging. This session pairs well with the Advanced Common Table Expressions session.
This session will include the following topics:
- Introduction to Memory Tables and CTEs
- Simple CTE
- CTE Instead of a Derived Table
- Multiple CTE in a Query
- Data Paging
- CTEs in Stored Procedures, Functions and Views
- Introduction To Recursive CTEs
At 10:45 I will be giving the Advanced Common Table Expressions Session.
Download the presentation here: Introduction to CTEs.zip
Related Posts:
- Writing Your First Common Table Expression with SQL Server
- Video: Writing Your First CTE with SQL Server
- Common Table Expressions – Terminating the Previous Statement
- CTE Scope
- Introduction to Recursive CTEs
- Recursive CTE for Dates In A Year
- Expanding on Recursive Dates CTE
- Multiple CTEs in a Query
- Nested CTEs
- Nested CTE’s Gone Wild – The Video
- CTE Data Paging
- CTE Data Paging in a Procedure
- Using a CTE in a Function to Split Up a Query String
- Using a CTE to Split a String Into Rows
- Can we use CTEs use in SSRS?
- CTE Hierarchy compared to the alternative
- Calculating Factorials with a Recursive CTE
- CTE – With An Insert Statement
- Fibonacci Sequence
- Generating a Tree Path with a CTE
- CTE Query Performance
- Multiple CTE’s in a single Query
- Recursive CTE’s
More from Stedman Solutions:
Steve and the team at Stedman Solutions are here for all your SQL Server needs.
Contact us today for your free 30 minute consultation..
We are ready to help!
Leave a Reply