Sort the results after search

Sort the results after search

RoToRoTo Posts: 1Questions: 1Answers: 0

Hello everybody,
I have a problem and I hope it can be implemented with datatables.

I want to sort the results of my search:
The result with the most suitable search criteria should be at the top and then sort in descending order.

At the beginning the table is sorted by ID - 1-30

I have already tested so much that I have lost track of everything.

Is that possible? And if so, how?
Can anyone give me food for thought?

Thank you and best regards!

Answers

  • kthorngrenkthorngren Posts: 21,166Questions: 26Answers: 4,921

    The Datatables search filters the table and removes rows that don;'t match the criteria. If I understand your requirement you don't want to remove rows but move the matching results to the top. If this is what you are looking for it would take custom coding on your part. Some options to customize the Datatables search and sorting are to use Orthogonal data and to create your own search or sorting plugins.

    Please provide more specifics if this doesn't help.

    Kevin

This discussion has been closed.