Viewing 3 posts - 1 through 3 (of 3 total)
Jeff,
This was timely as we are working on a tree just like this. I'm curious what you think about replacing the SortPath with a hierarchyid data type?
Glenn
September 19, 2014 at 7:26 am
CREATE FUNCTION [dbo].[Split](@data VARCHAR(MAX), @delimiter VARCHAR(20))
RETURNS @t TABLE (Element VARCHAR(MAX))
AS
BEGIN
DECLARE @textXML XML
SET @textXML = CAST('<d>' + REPLACE(REPLACE(REPLACE(@data,'&','~~amper~~'),'<','~~lt~~'), @delimiter, '</d><d>') + '</d>' AS...
February 25, 2011 at 1:46 pm
You should use ROW_NUMBER() instead of rank. Rank will assign the same number to the first to items in your data set. They are both 1 so...
November 20, 2009 at 7:03 am
Viewing 3 posts - 1 through 3 (of 3 total)