Hi everyone,
There is a read-only grid that uses a record-type data source. The table structure is as follows: Request Id (Primary Key) Name (varchar) In the grid filters, I’m applying a filter on the Request Id using the IN operator, and passing the values {9, 5, 3}. However, the grid displays the results in sorted order as {3, 5, 9}. I want the grid to display the records in the same sequence as the values I pass in the filter — i.e., {9, 5, 3} — without sorting them. How can I achieve this?
Thanks in advance !
Discussion posts and replies are publicly visible
A database or record query will not return the data in such a specific order.
You need to query the data separately into a local variable. Then you can iterate on the PKs and fetch the items from the result set in that order. Then you can feed that final list into the grid.
Thank you for your reply Stefan Helzle if we use data source as one local variable then export excel will not work
True. But if you need this, I do not see any option to implement your requirement.