I have a table which has the below schema. I need to get the sum of the quantity for each part number, by grouping the rows on both part_number and unit_price.
Schema: (part_number | unit_price | quantity)
I have seen this GroupBy method in LINQ. But I am not sure whether we can use it to get my solution.
Additionally, I saw a Compute() on data table which can be used to calculate the sum/average etc. on data table columns.
But, I am unable to figure out how to select the sum of quantity, by grouping on two columns (part_no, unit_price). A little help would be really appreciated.
Thanks in advance.