Data table changes my data order
Data table changes my data order
shaharNardia
Posts: 3Questions: 1Answers: 0
Hello, I have a table returning from my data base at a specific order.
for example my columns are - ** id | user | email | age**
and my server side returns this table order by age but the data table will order the table with the first column always.
I know I can use - ----"serverSide": true---- but I would like to keep the sorting, pagination, searching etc at the client side and not use ajax, is there any solution for that?
Thank you very much for your help,
Shahar.
This discussion has been closed.
Answers
You would use
order
to configure which columns the table is ordered by. By default its column 0.Kevin
Thank you for your reply but it won't fit for my needs, I have a dynamic store procedure that returns db ordered by other column every time...
I just want the option to print the db table as returned from db and afterwords get the abilities of client side.
Use the
order
option Kevin mentioned and set it to be an empty array. That will cause the initial display to be in whatever order the server returned it in.Allan
Thank you very much guys!
It works