Avatar

order by the order of 'in' operator

Aaron Zhou

There is an 'in' operator in the 'query' parameter of records.json, like below:

Record_number in ("8", "2", "11"......)

I would like to know if there is a way to order the query results by the order of record numbers' order in 'in' operator?

Follow 3 followers
1

3 comments

Avatar
Junko Werner 1 vote

Hi Aaron,

In Kintone, sorting can only be done in ascending or descending order. It cannot be sorted in the order of "in". If you want to do,  you have to create a process to do the sort based on the information obtained.

 

1
Comment actions Permalink
Avatar
Aaron Zhou 0 votes

Hi Gus, Junko,

Thanks for your help.

I referred the page before, but I am considering using the 'in' operator to retrieve records according to given record numbers in one of my use scenario.

I guess I have to create a process to do the sort locally after I got the records as Junko suggested in this case.

0
Comment actions Permalink