Selecting all the rows based on distinct column value

Posted by Santhosh.Nallavelli under C# on 8/8/2012 | Points: 10 | Views : 1438 | Status : [Member] | Replies : 1
Hi All ,

I have a Datatable say , having column column1,column2,column3.

ex data
column1 column2 column3
A xyz pqr
A asd poi
B zxc mnb
B 123 456
Now i want to export it to excel in the following way

column2 column3
A
xyz pqr
asd poi
B
zxc mnb
123 456


Please tel me how to get the desired output as shown above .




Responses

Posted by: Oswaldlily on: 8/8/2012 [Member] Starter | Points: 25

Up
0
Down
select distinct column1 from tablename =>avoid duplicate rows


from gridview to excel????

Santhosh.Nallavelli, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response