How to sort the columns of a list with structure datatype
Application Type
Traditional Web
Service Studio Version
11.9.0 (Build 33413)

Hi All,

Currently I have a table records showing the data using a local variable with structure list datatype and I found that the List_sortcolumn widget is not working although I have already assigned the entity and column name. Does that mean I need to use ListSort action or anything??

Rank: #99

Hi J U N I O R,

Can you share with us your OML or some prints of your code to take a look?


Best regards,

Ricardo M Pereira

Rank: #70

Hi Junior,

If you are using a structure I presume you are using Advanced SQL and in that case you will need an Order by parameter with Expanded Inline = True.

You then need to fill it with the default with something like this:

Where table records is the name of the Table Records input and the second parameter is your default order value, the SQL field you want to order in {Entity}.[Attribute] format like you would do on normal SQL.

The same type of values you use on the List_SortColumn widget:

I built a simple example OML for you in attachment.

Hope it helps.



Rank: #12540

Hi All,

My local list to have the sorting is a list with structure datatype that consists only structure attributes to hold those 'group by' elements from aggregates in preparation. How can I sort purely on the list only without using aggregate?

Rank: #295


You can use ListSort() action by dynamically passing the column names you have chosen and sort it according to Ascending and descending order using a boolean local variable 'IsAscending'.

Hope this helps, Thanks :)