We have a read only grid column which displays a decimal value. The value can have positive, negative or blank values.
What we want to do is always keep the blank values at the bottom. So when user sorts by the column either ascending or descending, it should only sort non blank values and keep blanks at the end.
Is there anyway to achieve this in appian with read only grid?
Discussion posts and replies are publicly visible
You'll have to roll your own sorting algorithm in order to do that.
It should actually be relatively straightforward. You'd pull a list of all nulls stored in a local variable, then filternulls to get the null-less list in another local variable, the sort the null-less list ascending or descending, last append the list of nulls you got from step one to the end of the sorted sub-list.
Issue is not the sort expression. It is the limitation of the grid control. It does not allow you to specify an expression at the grid column level. It only accepts a "sort field". So in that case you can only specify one set of values. And because we have negetive, positive and blank values, it is not possible to keep the blanks at the bottom. (unless someone knows how to do that). If there was a sort event or instead of sort field, it accepted sort expression, we can easily achieve this.
© 2023 Appian. All rights reserved.