Is it possible to set serverSide:false if totalrecords is less than 5000 ?

Is it possible to set serverSide:false if totalrecords is less than 5000 ?

DharmarajDharmaraj Posts: 4Questions: 2Answers: 0

Hello,

I am facing an issue to change "serverSide" option to false if records are less than 5000. If records are greater than 5000 set "serverSide" option to be true.

Is it possible to get both client and serverside processing?

This question has an accepted answers - jump to answer

Answers

  • colincolin Posts: 15,240Questions: 1Answers: 2,599
    Answer ✓

    Hi @Dharmaraj ,

    I had answered this one for you on StackOverflow first thing this morning, but I see you've removed the thread...

    As I said there, you can run an initial Ajax query, count the records, and from there conditionally initialise the table's serverSide option. 5000 is still a lot, so you'll want to benchmark on various clients to ensure performance is satisfactory.

    Cheers,

    Colin

  • DharmarajDharmaraj Posts: 4Questions: 2Answers: 0

    Did the same thing. works well @colin

This discussion has been closed.