datatable sorting false Example

datatable sorting false : Enable or disable ordering of columns. jquery datatables disable sorting row, disable sorting one column Also This post shows you how to disable sorting in jquery datatable.

datatable sorting false

here we can learn to jquery datatable disable sorting on specific columns. as well as Source code for disable sorting for multiple column.

Disable Sorting On Specific Columns In Datatable

Datatable disable sorting on particular column example

You can see sample code of columnDefs:

'columnDefs': [ {

    'targets': [1,3], /* your html tabel column index */
    'orderable': false, /* true or false */


Don’t Miss : Disable sorting in datatable for one column

Also Read This πŸ‘‰   jquery replace newline with br Example - Convert new lines to br - nl2br function

Use the following code to disable ordering on first column:


     'processing': true,
     'serverSide': true,
     'serverMethod': 'POST',
     'ajax': {
     'columns': [
        { data: 'id' }, /* index - zero */
        { data: 'member_name' }, /* index - first */
        { data: 'email' }, /* index - second */
        { data: 'mobile' }, /* index - thired */
        { data: 'country' } /* index - fourth */
     'columnDefs': [ {
        'targets': [3,4], /* column index */
        'orderable': false, /* true or false */

Don’t Miss : Disable row in DataTable jquery

Also Read This πŸ‘‰   how to pass parameter in onclick function in javascript?

I hope you get an idea about datatable sorting false .
I would like to have feedback on my blog.
Your valuable feedback, question, or comments about this article are always welcome.
If you enjoyed and liked this post, don’t forget to share.