52
Views
9
Comments
Solved
How do I associate a table to an Aggregate?
Question

Hi Everyone, I'm a new outsystems developer.

I have a main page with few tables, I would like to associate a Aggregate for each table, its mean that I need to have a different filter for each table.


I tried with Events On sort configuring a Refresh data, but its doent work. 




screen1.jpg
2024-12-10 04-40-04
Gitansh Anand
Solution

You should go through the Reactive Web Developer course.
Here are some parts of the course related to your issue:
1. Aggregates 101
2. Building Screens with Data
3. Pagination and Sorting

Thanks
Gitansh Anand

2024-11-25 22-05-29
Sergio Aznar Guallar

Hi Fernando,

the best way to do it is using a different aggregate to each table, so you can apply different filters to your tables


Kind regards,

Sergio

2024-12-10 04-40-04
Gitansh Anand

Hi Fernando, I am adding an OML; please see if it helps you.
All you need to do is drag the entity directly to your screen, and OutSystems Accelerator will do the work for you.

Thanks
Gitansh Anand

Test.oml
2024-12-10 04-40-04
Gitansh Anand

Do keep in mind when I say Accelerator will do the work that it will only create the pagination and dynamic sorting logic; you will need to add other sources, joins, and filters as required. 

2021-09-29 19-35-12
Mathavan Venkatraman

Hi Fernando,

You can join multiple tables in a single aggregate with appropriate joins and you can have multiple filter conditions as well on the individual tables. Hope this helps your requirement.



Happy coding!

Mathavan

2023-03-22 16-58-21
Fernando Araujo

@Sergio Aznar Guallar @Gitansh Anand @Matthias Sevenant 

In the screenshots has what I doing.

I configured differents sources for each table.

Do I need to create a Variable's structure as the screen1?

what is the logic to do this?


Thank you




Aggregate .jpg
table2.jpg
table1.jpg
screen1.jpg
2024-12-10 04-40-04
Gitansh Anand

Yes, for each table, you should keep separate variables for sorting and pagination.

2024-12-10 04-40-04
Gitansh Anand
Solution

You should go through the Reactive Web Developer course.
Here are some parts of the course related to your issue:
1. Aggregates 101
2. Building Screens with Data
3. Pagination and Sorting

Thanks
Gitansh Anand

2023-04-16 15-25-31
Krishnanand Pathak

Hi Fernando,


You should use separate variable for every table aggregate used on the screen like TableSort, StartIndex and MaxRecords(If required) and also separate actions for sorting and Pagination.
So, that they will not distrube each other.


Regards
Krishnanand Pathak

2023-03-22 16-58-21
Fernando Araujo

Thank you ! I got it, I dont understant pretty good but its working.

I will post a new question, please help me to improve it!


thanks again.

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