Best way to display grouped by aggregate data?

0
Hi, I'm looking to display some very simple grouped by data with associated sums.  I can't find any Mendix built-in functionality that can groupby so I'm looking into alternatives.  I've been reading about OQL and think this might be the simplest route for me, but I don't know where to enter in the OQL code.  All of the references on the internet show how to write it, which I'm pretty ok with just don't know how to use it. If anyone has other alternative recommendations for what I'm trying to do, I'm open to that as well.  
asked
2 answers
0

Hi Cole,

You can use OQL in a dataset to display data. 

https://docs.mendix.com/refguide/data-sets

What exactly are you trying to do?

 

Edit:

Maybe this blog will be of more help.

https://github.com/ako/QueryApiBlogPost 

Sorry I dont have too much experience with OQL.

 

Can you not accomplish what you want to do with a datagrid and listening widget? 

https://docs.mendix.com/refguide/listen-to-grid-source

 

I'm not too sure what you are doing but you can show associated data this way. I used a datagrid on the left and a listening widget with a datagrid over association inside of it. Now when I select a row from the grid on the left, the right grid will show the associated data. 

answered
0

Cole,

I created a small test. Here is the Group/Details data:

and here is a sample page that displays the data grouped with subtotals:

I used the following domain model for this example

and the page that shows detail grouping with subtotals looks like this:

I calculated the group totals in a microflow.

Maybe this example will give you some ideas about how to do what you need to.

Mike

**EDIT**

How to populate group totals

answered