17
Views
1
Comments
Aggregates
Discussion

Consider that you have two Aggregates on Screen where one depends on the output of the other one, and only the output of the second Aggregate will be used on the Screen, According to OutSystems' best practices, what is the best option to implement such a scenario?

A) Use a Data Action to execute the two Aggregates following the desired order. Set the output parameter of the Data Action to include the information required by the Screen.B) Create the two Aggregates directly on the Screen. Set the Fetch property of the first one to At Start and the Fetch property of the second one to Only on demand. Then, use the On After Fetch Handler of the first Aggregate to run the 2nd Aggregate.C) Use the On Ready Event Handler of the Screen to execute the two Aggregates following the desired order. Save the information required by the Screen in a Local Variable.

D) Create the two Aggregates directly on the Screen, both with the Fetch property set to At Start.

2026-02-26 06-29-24
Rahul
 
MVP

Hi @Ranjith ,

The best practice is - 

option A provides a clean, scalable, and efficient solution for managing dependent Aggregates, aligning with OutSystems best practices for data management and screen optimization. 


Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.