ORDER BY a column from a rowlink

I'm quite new to Honeycode and trying to customize the to-do app template. I'd like to have a filtered list of tasks ordered by their priority. I've created a priority table to populate the picklist and given it a 'sort order' column. However, in my filter function I get an error when trying to order by "Tasks[Priority][Sort Order]". I think it takes issue with trying to access the sort order through the 'priority' rowlink, but this syntax works fine when used as the filter condition "Tasks[Priority][Sort Order]=%".

Any ideas what I'm doing wrong? Does ORDER BY support accessing columns through row links? I'd prefer to avoid putting the sort order in the priority name if possible.

Thanks!

Hi @Nich-dc32,

Thanks for posting, and welcome to the community! :honeybee: :honey_pot:

For this, you would order by the rowlink as Tasks[Priority] without specifying the additional column. Meaning your formula may look something like:

=FILTER(Tasks,"ORDER BY Tasks[Priority] ASC")

I'll show you an example set up, so you can create a similar data model.

I have a Priority table that has a column for the sort ranking only:

And a Tasks table that has Priority column that's formatted as a rowlink to the Priority table:

And in Builder, the filter formula for the sort order of the list is:

This how it looks in app:

I'll also note that you can use the filter and sort features in the Display tab of the properties, if you'd like to add in-app user controls:

Hope this helps! Let us know if you have any other questions. :honey_pot: :slight_smile: