I am using jquery datatable, I want avoid a column while sorting other columns, that is that column should remain static.
Asked
Active
Viewed 132 times
1
-
Can you give an example of the result of this sort? – John Clifford Mar 08 '16 at 11:20
-
I hope this might help. http://stackoverflow.com/a/4672946/4672534 – rmondesilva Mar 08 '16 at 11:25
-
@rmondesilva this is for disable sorting a particular column, while sorting other columns it will affect. My requirement is that column should not be change, i should remain same – user3189828 Mar 08 '16 at 11:28
1 Answers
0
Use "orderFixed". Read https://datatables.net/reference/option/orderFixed
"orderFixed": [ column index, sort ];
$('#tbl').DataTable({
"orderFixed": [ 0, 'asc' ]
});

rmondesilva
- 1,732
- 3
- 17
- 29
-
it is not working. while sorting other columns the value inside fixed column also affected – user3189828 Mar 08 '16 at 11:46
-
It works on mine. I think it's better if you will also post your codes. So we can see the problem clearly why it does not work. – rmondesilva Mar 08 '16 at 11:50