Sort by multiple categories


Im new to glide and have no coding experience.
I understand the basics of Glide, and have made some basic apps.
What Im trying to do now is to have an inventory app where I want to be able to sort by Name, Sex and Size.

Say that in my inventory, I have different Jacket, Pants and T-Shirts. All of them are in different sizes and for both sexes. So lets say each item have 8 variations (Male S, Male M, Male L, Male XL, Female S, Female M, Female L, Female XL) So for these three items, there are 24 different variations.

I would like that the first list only show the uniqe names of the items. regardless of size and sex:


When selecting that item, the next list will be:


Then the availible sizes for that sex


Then when selecting that size, it will show the detail screen for the item matching the previous selections.

Im thinking that this has to be set ut via different relations columns, but as Im new to glide, all the relations are a little bit confusing, so some help here would be appreciated.

Or are there any other ways to accieve the same results with choice componets or similar?

I think you mean a filter, rather than a sort?

From what you described, I think you can do something like this.

However, please beware of the edits count this solution will consume.

1 Like

Thanks for the quick reply.

I guess that I can accieve the result by this filter-method, but thats not what I was thinking.
But Im not sure if what Im thinking about is possible.

In my inventory, i have these columns:

Item name, Gender, Size, Quantity

There will then be multiple rows with the same Item name, but different gender and size:

  1. Jacket, Male, S, 10
  2. Jacket, Male, M, 12
  3. Jacket, Male, L, 3
  4. Jacket, Female, XS, 3
  5. Jacket, Female, S, 5
  6. Jacket, Female, M, 2
  7. Pants, Male, L, 3

And so on.

On screen one, if i choose a list from that table, it will show all the jackets with the same name, regardles of gender and size.

I would like the first screens list to only be:


Then, on the second screen, only show the genders.
On the third screen, Show Sizes
And when selectic the size, show the detail screen of the item matching the selected Item name, Gender and Size.

Maybe what im trying to do is not possible, or to complicated for me.
So maybe I will just do the filter-option.

Why do you need it to navigate through 3 different screens though? Wouldn’t it be better for the user if you just show everything on one screen, and only show the items when all values for the type (jacket/pant), gender and size are filled?

I have now done the filter-option. Works great.
But like you said, it can generate a lot of edit counts.

I also wanted the other option to learn more about how relations work, since this is new to me.
But I have now made a working and suitable app with the use of the filtering system you linked to. :slight_smile:

1 Like