Hi Team,
I want to print infinte number pyramid in sqlserver like
ab
abab
ababab
ababab
and after print i want to reverse like
ba
baba
bababa
babababa using CTE.
Please suggest how can do this.
My Second Question :
Hi Team,
I have one table and inside table two columns id , value
id value
1 a
1 b
1 c
1 d
2 a
2 b
I want to ouput like
id Value
1 a,b,c,d
2 a,b
please write query for above question.

Manas MohapatraRank #182 · 13.2K reputationPosted May 10, 2017, 8:56 PM EDT
Dharmraj ThakurRank #577 · 4.2K reputationPosted May 10, 2017, 10:44 PM EDT
Davin MartynRank #285 · 8.8K reputationPosted May 12, 2017, 4:15 AM EDT
Suvendu Shekhar GiriRank #546 · 4.4K reputationPosted May 10, 2017, 6:45 PM EDT
Davin MartynRank #285 · 8.8K reputationPosted May 10, 2017, 8:34 PM EDT
i have no idea how to do this in sql. i am on learning stage