John Hammond

John Hammond

  • NA
  • 16
  • 8.8k

Covert a list of columns to rows

May 2 2014 1:40 PM

If I have a< list of transactions> that looks like the one below.How do I convet the rows into columns in C#.

 

 

Date       Datatype   outlet   AMT

1/12/12   SUM           A          80                   

1/12/12   SUM           B          70

1/12/12   SUM           C          60

1/12/12   COUNT      A          15

1/12/12   COUNT      B          15

1/12/12    COUNT     C          10 

 

This is how I want it to look ANY HELP.  Thanks

I want my other list to look like this

 

Date          Datatype        A      B          C

1/12/12         SUM            80    70       60

1/12/12         COUNT         15    15       12


Answers (1)