• The split function you cited returns table of VARCHAR(8000) because this is what Item = SUBSTRING(@pString, l.N1, l.L1) returns due to it's first argument type. Provided Call_Detail_Report_Repository.NodeTraversed is the result of the split function, you need to CAST it to VARCHAR(MAX) explicitly.