Hi Friends
How to write a query to achieve the following task in TSQL:
Col_1 Col_2 Col_3 Col_4
A B NULL D
A B C NULL
To A, B, C
A, B, C
I wrote a query like this: select Col_1+','+Col_2+','+Col_3+','+Col_4 from table
and I'm getting result like this: A, B, , D (as Col_3 is NULL)
A, B, C, (getting comma after C as Col_4 is