How CTE really works?
I came across this CTE solution for concatenating row elements and I thought it's brilliant and I realized how powerful CTEs can be. However, in order to use such a tool effectively I need to know how it works internally to build that mental image which is essential for beginners, like me, to use it in different scenarios. So I tried to slow motion the process of the above snippet and here is the code USE [NORTHWIND] GO /****** Object: Table [dbo].[Products2] Script Date: 10/18/2011 08:55:07 ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO IF OBJECT_ID('Products2','U') IS NOT NULL DROP