I have a Table component on my Low Code app, which displays IP information.
When we try the sort the Column with the IP information, the sorting is currently done as a 'string'. As can be seen on the image below.
Would there be any way we can get this to sort as an 'IP Address'? This would greatly improve the user experience when looking through the information.
Thanks for the help!
As Toon already mentioned, there is currently no way yet to get a custom sort order for columns; they all use the default comparison for their column type.
A possible solution is to use a custom operator in the following way:
- Remove the original 'Network address' string column
- Add a new 'Sortable network address' column of type integer
- Fill in the cells of the new column as such:
- Value = the IP address ranking
- DisplayValue = the original IP address string
This ensures that the user only sees the IP string and never the underlying integer ranking.
It also still allows the user to sort dynamically by clicking the column header.
The script could look something like this:
There is no such thing as "natural sorting" (aka finding the multiple digit numbers in pieces of text and combining them into one for sorting purposes) in low code apps and dashboards right now. You will also notice this when using numbers in your folder structure in dashboards for instance.
You could use a custom operator for your GQI query to implement this in your use case though (still in soft-launch).