Hi Expert,
I have an excel file and i wish to make pivot values in the table.
how can i aceive this by LINQ?
Pivot.xlsx (10.0 KB)
attached the input and expected the output in the excel file for your reference.
Hi Expert,
I have an excel file and i wish to make pivot values in the table.
how can i aceive this by LINQ?
Pivot.xlsx (10.0 KB)
attached the input and expected the output in the excel file for your reference.
use build datatable and create a table with 3 columns
use assign with this
newdt = dt.AsEnumerable.GroupBy(function(x) {x("Date").ToString,x("Status").ToString}).Select(function(x) newdt.LoadDataRow({x.First()("Date").ToString,x.First()("Status").ToString,x.Count.ToString},False)).CopyToDataTable
cheers