Changing the data limit when exporting to Exccel
Changing the data limit when exporting to Exccel

Currently I'm using Datatable to fill up all my data in 10 rows each using pagination. For this I've mentioned in my model a length and start value like so:
$this->db->limit($length,$start);
Now I recently added the Datatable.buttons library for the export to excel functionality. So now I have added the following code to my AJAX call:
dom: 'Bfrtip',
buttons: [
{
extend: 'excelHtml5',
exportOptions: {
columns: ':visible'
}
},
'colvis',
],
Now I can successfully export the data to an excel sheet, but it only exports the 10 entries that are shown in the respective pagination page. I want to be able to manually specify that I want to retrieve the first 1000 or 2000 rows
Answers
If you're using
serverSide
, then only the data you can see can be exported, as the client has no knowledge of what's remaining on the server. There are a few threads discussing this, such as here and here, that may get you going,Colin