Ascending vs Descending Order

2X_c_cb809c94d6bc9ac47d21b3d0277e77593218a5e5.png

[1st Picture] I have a simple table containing a column named “Gone”. The column keeps 2 possible words; “No” and “Gone”.

[2nd Picture] In UX, setting “Sort by” in “Ascending” order makes “No” come before “Gone”.

[3rd Picture] “Descending” order makes “Gone” come before “No”.

Why are they upside-down?

Regards,

Solved Solved
0 20 629
  • UX
1 ACCEPTED SOLUTION

I tested more deeply and it seems that if the option “Use other values” is not set as ON, it will follow the Enum field’s option called “Values”. Now when you have them as an order No > Gone and that option is set as OFF, this will happen.

View solution in original post

20 REPLIES 20

Interesting, if I change “No” to “Not”, AppSheet sorts “Not” and then “Gone” correctly. However, “No” are still down below.

It sounds that the view is trying to be clever and using “No” as FALSE. What column type are you using?

Type is “Enum”.
Base Type is “Text”

Regards,

Please check that your column type in the spreadsheet is set as “Plain text”. Now it’s probably set as “Auto”.

I just changed it to “Plain text” as your suggestion. However, it does not help.

Regards,

And you synced after that change?

To make sure the entire format changing. I did,
-Change column format from “Automatic” to “Plain text”.
-Copy all data in the column to a new file using “Paste values only”.
-Delete all data in the column.
-Copy all data from the new file back to the column using “Paste values only”.
-Open new tab in Chrome and open AppSheet editor.

Nothing changed.

Regards,

@Aleksi

I suspect your column name might be causing a problem. What’s happening when you change the column name like “Gone?”

The column name is already “Gone”. And the word “Gone” should not have anything to do with logical processing (it is not “Yes” “No” “True” “False”).

I thought the appsheet might be confusing something as the column name is used as well as value of the same column . So I just said you try to use the other field name . Just even add question mark to the end.

AppSheet interprets the first row to always be column name. This should not fool the AppSheet operation.

Okey I have no more words then.

Thanks for your advice. But changing column name may affect the app. So, I try to avoid this.

I tested exactly with your definitions and for me it’s working just fine.

This behavior is the same on both the Editor’s emulator & on my Android phone. I have to use “Ascending” as work around.

Is it possible that you have changed the column name slightly and you haven’t changed the column from your View definition?

I don’t think so because I created the spreadsheet file with “Gone” column since the beginning.

2X_5_5aaa03483d4adcb5d8f5af51827745f449d5f802.png

I think I found a clue. If I move the Values upside down to “Gone” and then “No”, the view sorting is correct.

However, the sorting algorithm in AppSheet should not be depend on the order of the Value itself. It should rely on the content inside column, not the sequence of the list.

Regards,

I tested more deeply and it seems that if the option “Use other values” is not set as ON, it will follow the Enum field’s option called “Values”. Now when you have them as an order No > Gone and that option is set as OFF, this will happen.

2X_d_defa5cc745852fa7a5165356722cbc0a7d3550e1.png

Thank you.

I finally choose to change “Allow other values” to “ON” and keep the “Input mode” as “Buttons” to prevent users from adding any new options. Now I can use “Descending” which looks more rational.

However, it’s still weird anyway.

Top Labels in this Space