How to sum values in a sorted table [closed] - Hack The Tech - Latest News related to Computer and Technology

Hack The Tech - Latest News related to Computer and Technology

Get Daily Latest News related to Computer and Technology and hack the world.

Friday, June 11, 2021

How to sum values in a sorted table [closed]

I have the following table, I never know how many provinces or which provinces will appear in the table results. The results are sorted by province.

enter image description here

I would like to separate and sum the column totals by the provinces, that appear in the results. Is there a quick way of doing this in a foreach without having to do an if statement for each province ? For example if(Province=='AB'){do the math on the column}.



source https://stackoverflow.com/questions/67926728/how-to-sum-values-in-a-sorted-table

No comments:

Post a Comment