I have this data in a Google DataTable:
project1 | system1 | 5
project2 | system2 | 2
project1 | system1 | 5
project3 | system4 | 1
I need to merge rows that have the same projects and systems. So the result would be:
project1 | system1 | 10
project2 | system2 | 2
project3 | system4 | 1
the number must be a sum of the values in the respective columns.
Is there a build in method in the DataTable to achieve this or can somebody give me a hint how to do this without the need of typical iterating through the table and comparing on each row.
populate your DataTable and use the group-Function for this: https://developers.google.com/chart/interactive/docs/reference#google_visualization_data_group
Your example should fit into something like this:
One last thing: you are talking about Grouping not Merging. 🙂