Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have the following table:
ORDER | VALUE |
---|---|
01 | X |
02 | A |
03 | B |
04 | C |
05 | Y |
06 | F |
07 | G |
What I need is to SORT the table like this:
ORDER | VALUE |
---|---|
01 | X |
02 | A |
04 | C |
05 | Y |
03 | B |
06 | F |
07 | G |
By showing number 03 after 05
Do you know how could I do this?
I used a quick fix by doing the following in the script: IF(ORDER='03','05.5',ORDER) AS ORDER
Then I SORT by Expression with field ORDER ascending (01 - 02 - 04 - 05 - 05.5 - 06 - 07).
Is there any other better way?
Thank you!!!
or may be this:
Match(ORDER, '01', '02', '04', '05', '03', '06', '07')
Seems like a good way to handle it. What's the concern here?
I wanted to know if is there any direct way to use from SORT in Expression instead of touching the script?
Have you tried this expression for the sort expression:
IF(ORDER='03','05.5',ORDER)
or may be this:
Match(ORDER, '01', '02', '04', '05', '03', '06', '07')
Thank you!!!