Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
subbu_mareedu
Starting Member
11 Posts |
Posted - 2014-04-06 : 05:52:10
|
hai friends iam new to sql server.i have a table with data as shown belowcol1aaaaaaaaBut i want my result for same data likecol1a0 a1a2a0a1a2a0a1a2Can u give the solution for this problem friendssubbu |
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2014-04-06 : 06:11:05
|
[code]select col1 + convert(char(1), (row_number() over (order by col1) - 1) % 3)from yourtable[/code] KH[spoiler]Time is always against us[/spoiler] |
|
|
subbu_mareedu
Starting Member
11 Posts |
Posted - 2014-04-07 : 01:29:12
|
Thanks khtansubbu |
|
|
|
|
|