I did not think like that :).Thank you for the idea,Okay I will try this solution.By the way in the early version of my code, before I will change it to serverside.
dataarray.forEach(function(d){
if ( table.rows('#'+d.DT_RowId).any(d.DT_RowId) ) {
console.log('already exist cannot be added');
}else{
table.row.add(d).draw();
}
});
the logic of serverside in receiving the data by assigning the result to variable. So I can also Assign the result to a variable instead of doing adding rows and checking if it exist. ?. Am I right ?
Yes, you need to trigger the callback from the socket handler on reception of server-side processing data. You could store the callback in a variable for example.
I think I am in big trouble in implementing the serverside using socket.io because I am using node-mysql for my database. and I need to convert your ssp.class to node-mysql.but I need to find way first if there is another solution for this to use the ssp.class
I don't have an example I can send you as that isn't code I've written before. I would be happy to put one together for you though - the Quick Support 180 option will cover the work involved.
Answers
Hi @allan,
I did not think like that :).Thank you for the idea,Okay I will try this solution.By the way in the early version of my code, before I will change it to serverside.
the logic of serverside in receiving the data by assigning the result to variable. So I can also Assign the result to a variable instead of doing adding rows and checking if it exist. ?. Am I right ?
Thank you in advance.
Yes, use a variable. But with server-side processing you don't use the API, you call a callback function - see the
ajax
documentation.HI @allan,
Just like this example
best regards.
jemz
HI @allan,
I am confuse in using the callback here
Thank you in advance
Yes, you need to trigger the callback from the socket handler on reception of server-side processing data. You could store the callback in a variable for example.
HI @allan,
I think I am in big trouble in implementing the serverside using socket.io because I am using node-mysql for my database. and I need to convert your ssp.class to node-mysql.but I need to find way first if there is another solution for this to use the ssp.class
Thank you in advance
I don't have an example I can send you as that isn't code I've written before. I would be happy to put one together for you though - the Quick Support 180 option will cover the work involved.
Allan