« 4/4/07: Another use of T-SQL 2005… | Main | 4/13/07: Processing data using ADO.NET in VS2005 »

April 05, 2007



Brilliant, just what I wanted and very timely too. I have a quick question though which may or may not be possible with CTEs.

Looking at your example of getting all the children for a given parent how would you add a "level" column to the result to indicate the heirarchical level below the parent of the child. This would come in handy if you were using the result to populate a tree view as you would need to ensure that the parent nodes were added prior to their children.

I can do it in VFP but seeing as we are moving from VFP to .NET & SQL Server.

Kind regards,

Phil, UK

The comments to this entry are closed.