Search and Update a column value

Search and Update a column value

ravikiranketheravikirankethe Posts: 11Questions: 5Answers: 0
edited August 2014 in Free community support

I have a requirement that user will enter some information and if that exists in the table (search in one of the column), that row needs to be updated with the new values or else add a new row to the table. How to achieve this functionality?

I was able to add a row as below:

 
      var table = $('#tbl_track_colo_list').DataTable();
      table.row.add( [
         $("#sel_emtr_colo option:selected").val(),
         $("#host_count").val(),
         $("#event_size").val(),
         $("#event_count").val(),
         $("#peak_event_count").val(),
         $("#yca_role").val()
      ] ).draw();

Answers

This discussion has been closed.