Sorting an alpha-numeric list

Hi,

I'm having difficulty sorting text column into a descending order list.

I'm getting this result:

1A , 1B , 1C , 23A , 24A , 29A , 2A , 2B , 2C , 31A , 3A , 3B , 3C , 81A , 81C

The result I'm after is:

1A , 1B , 1C , 2A , 2B , 2C , 3A , 3B , 3C , 23A , 24A , 29A , 31A , 81A , 81C

I'm using this select:

 

UNIQUE(
SORT(
SELECT(
assets[node_asset],
AND(
[floorplan_id] = [_THISROW].[id],
ISNOTBLANK([node_asset])
)
)
)
)

 

Thanks in advance... 😉

Solved Solved
1 5 331
1 ACCEPTED SOLUTION

Yes, AppSheet sorts in the way @T_I_Phong mentioned. To get the sort order you desire, I believe it will call for some longish configuration.

I tried and even posted an expression but I realized that it is also failing..

If it is must , we could give it a try to come up with a configuration. However you may want to evaluate if the need will justify a longish configuration. We may need to add a few extra columns to achieve it.

BTW could you update where exactly this expression is used?

Edit:

Please try an expression something like 

UNIQUE(
SORT(
SELECT(
assets[node_asset],
AND(
LEN([node_asset])=2,
[floorplan_id] = [_THISROW].[id]

)
)
),FALSE
) +

UNIQUE(
SORT(
SELECT(
assets[node_asset],
AND(
LEN([node_asset])=3,
[floorplan_id] = [_THISROW].[id]

)
)
),FALSE
)

View solution in original post

5 REPLIES 5
Top Labels in this Space