Expand my Community achievements bar.

Iterate and Aggregate Program>Projects>Tasks

Avatar

Level 10

Hi Fusion Community,

Can anyone provide instruction on how I can effectively look at programs and iterate down through their projects, their tasks, grab some data at the task level (Actual Hours), and then aggregate all Actual Hours for all of those tasks back up at the program level?

 

My scenario will be looking at a data store full of program ID's, so I'll want to do this separately for each program in a given scenario execution.

Thanks,
Nick

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

2 Replies

Avatar

Level 10

Hello Nick,

 

I would iterate through your data store and put each program ID into a Read a record module, which is configured like this:

lgaertner_0-1715625034622.png

 

By mapping the Collection to projects:tasks:actualWork, the module will provide a bundle for each program which includes all projects and their tasks.

 

lgaertner_1-1715625265047.png

 

After that comes the tricky part. You need to work with two iterators, one on the projects array and one the corresponding task array.

To sum everything up, you will need a Numeric aggregator module. The problem is to get the total sum on all operations, so you could work with a variable starting as an empty array, which the result from each operation are added to.

I am quite sure, that there are some optimization possiblities, but at the moment I do not find the perfect solution. I will think about it again and get back to this thread.

 

Regards

Lars

Avatar

Level 10

Thanks for this Lars!  Sorry for the late response.

I'm going to play with this and see if I can get something to work.  If you think of anything else, let me know.  Thanks again.