• jts_2003 (9/29/2010)


    2. You can build a recursive CTE - although I'm no sure I would want to 😉

    Recursive CTE'sare an invaluable tool when working with hierarchic data (like employee/supervisor relations, parts built of parts built of parts, genealogy data, etc). There are some examples of this in Books Online.


    Hugo Kornelis, SQL Server/Data Platform MVP (2006-2016)
    Visit my SQL Server blog: https://sqlserverfast.com/blog/
    SQL Server Execution Plan Reference: https://sqlserverfast.com/epr/