🔀 In-App Sorting (Simple Solution)

What’s up Gliders!

I recently came across a post asking about in-app sorting.

So I thought I’d create a quick video explaining how to add In-App Sorting to a Glide app so users can sort data as they please!

This seems to be a fairly simple way of getting it done, but I have no doubt there are numerous other ways to achieve the same end result (for example by using the new Query Column when working with larger sets of data)…

That’s the beauty of Glide, there’s always a way!

Cheers :beers:


Very nice, I like it :+1:

And of course that got me thinking… haha
mmm, two query columns, I think. Each returning the same but just sorted in the opposite direction. Then an if-then-else column to decide which one to use as the source of a collection. And then we’d only need a single collection.

But everything else the same, I think - I do like the way you set that up.


Haha I bet!! :rofl:

I played around with the two query columns initially (asc & desc) but it didn’t allow me to select the query column as a value in my if/then/else column (and the rest of the setup remained fairly similar i.e. conditionally hiding/showing tables on the front-end) so I thought I’d leave it as is…

Interested to see what you come up with! :brain:


oh, that’s interesting. mmm okay, I’ll have a fiddle later and will let you know if I come up with anything.


I think @Robert_Petitto did mention in his tutorial that the query column seems to give out a multi relation in terms of output and maybe that why it won’t show in the if-then-else column to be used…

Great tutorial though @Loqode
Keep it up :+1:

1 Like

How elegant!

For performance purposes we would want to avoid loading 2 long collections with images for instance. So like Darren I wonder if we could push the ascending/descending logic to the Data Editor to avoid having 2 collections. Query or Sort Array might be the way to go.

How very neat. Thank you for the inspiration :pray:


Very clean video; explains the concept nicely!

1 Like

Thanks Luther! Appreciate it.

And that’s interesting to hear about the multi-relation… If Glide allows Query columns to be used in if/then/else columns as values it would unlock a lot of power :thinking:

1 Like

Thank you @nathanaelb! Yeah I agree regarding the two collection tables… I feel like there’s definitely a way to do it without conditionally showing/hiding two collections on the front end.

Thanks David! Glad you enjoyed :pray:


1 Like

My thoughts too :thinking: Got excited for a minute there! :sweat_smile:


I opened that app to see something and got really excited to see that. Later realized it was a classic app.

1 Like

All good!! Hopefully they release native in-app sorting soon :crossed_fingers:


Hi Guys, Hi @Loqode ,
Followed your video, didn’t get it working with different users…I was thinking “what the hell…” then I noticed I missed the “make row owner” in users table…set it and Boom, perfect!

1 Like

Awesome Fabio! Glad you sorted it out!