c# - Append multiple column values into single column by adding column values below in datatable -
am having datattable below 3 columns name,favourite1 , 2.
name   favourite1   favourite2  xxx     eating       cricket yyy     books        music   my expected output is
name   favourites       xxx    eating         yyy    books          xxx    cricket yyy    music   how make ... :(
use code in c#. merge function used merge 2 data tables. expected output in fav1 datatable.
datatable fav1; fav1= threecolumntable.copy(); fav1.columns.remove("favourite2"); fav1.columns[1].columnname = "favourites";  datatable fav2; fav2= threecolumntable.copy(); fav2.columns.remove("favourite1"); fav2.columns[1].columnname = "favourites";  fav1.merge(fav2);      
Comments
Post a Comment