November 27, 2010 at 12:17 am
Hi,
I have created a function in which i want the result as comma separated like A,B,C
For that I had to combine the records which were there in different Rows
so for wach record in table, function is getting executed and it is fetching the data from the other details table, is there a way so i can have the Result like A,B,C and also i can avoid the cursor..!?
Thanks
Parth
November 27, 2010 at 2:24 am
You don't really need a c.u.r.s.o.r nor a function.
What you most probably can do: use FOR XML PATH('').
We'd be able to show you how it works but we don't have any sample data to play with.
So, all can provide is a link to a different post.
If you'd like to see a coded version using your data please read and follow the first link in my signature.
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply