Filter aggregate on multiple listbox selections

I would like to filter an aggregate on the selected values of multiple list boxes that contain the distinct values from multiple columns of that aggregate. I'm not sure if that is clear so I added screen shot. 

Is there some way in the filter to utilize the SQL 'In' as in "Where Column in ListboxSelectedValues"? 

Thanks.

Hey Bradford,


I would do that with an advanced query. For each list with selections, I would add them to the where clause as a parameter inside the 'in' statement. I would also need a function to get a list of ids and turn them into something like "(id1,id2,id3)" to be used inside the 'in' statement.

Márcio Lima wrote:

Hey Bradford,


I would do that with an advanced query. For each list with selections, I would add them to the where clause as a parameter inside the 'in' statement. I would also need a function to get a list of ids and turn them into something like "(id1,id2,id3)" to be used inside the 'in' statement.

By Advanced Query do you mean the SQL Widget next to the aggregate widget in the left hand side bar?


Hello 

I believe what you need is to write an advanced sql wherein you utilize the query parameter with its "expand inline" set to be true. 

Check out the documentation link below 

https://success.outsystems.com/Documentation/10/Reference/OutSystems_Language/Data/Handling_Data/Queries/Query_Parameter 


Bradford Jones wrote:

Márcio Lima wrote:

Hey Bradford,


I would do that with an advanced query. For each list with selections, I would add them to the where clause as a parameter inside the 'in' statement. I would also need a function to get a list of ids and turn them into something like "(id1,id2,id3)" to be used inside the 'in' statement.

By Advanced Query do you mean the SQL Widget next to the aggregate widget in the left hand side bar?


Yes, that's it.