How to get record if exists then change value for new
How to get record if exists then change value for new
przeqpiciel
Posts: 2Questions: 1Answers: 0
My code is very simple
var table = $('#summary').DataTable();
table.row.add(['111', 'wert56456']).draw();
table.row.add(['222', 'wert56456']).draw();
table.row.add(['444', 'wert56456']).draw();
table.row.add(['333', 'wert56456']).draw();
result = table.search('2348234');
console.log(result.row().data());
How to get specific row, eg. containing in first column 333 and change column to other value ?
Answers
Use the
row()
selector method with a suitablerow-selector
. For example:Then use
row().data()
orcell().data()
to update the data as needed.Allan
What an answer !!
I did it with filter()