Contents tagged with XML
-
SQL XML - TreeView
I sometimes forget how to do an XML output formed in a tree when dealing with a single table parent/child relationship. There is a great explanation on SQL Server Central on *how* to do this. I am mainly capturing the link and the SQL I just generated to do this. This query will drill down 12 levels at the most. Just alter the case statement (pivot) to go deeper.