oTable.fnUpdate skip a column
oTable.fnUpdate skip a column
Hello.
I'm trying to figure out how to skip a column.
For example, this works:
[code]
oTable.fnUpdate( ['a', 'b', 'c', 'd', 'e'], 1, 0 ); // updates node=1, columns 0-4
[/code]
This is identical:
[code]
oTable.fnUpdate('a',1,0); // updates the column 0 in row 1 with value 'a'
oTable.fnUpdate('b',1,1); // updates column 1 in row 1
oTable.fnUpdate('c',1,2); // updates column 1 in row 1
oTable.fnUpdate('d',1,3); // updates column 1 in row 1
oTable.fnUpdate('e',1,4); // updates column 1 in row 1
[/code]
Is it possible to update columns 0,1,2,4 in one line of code? Not sure how I'd indicate in the array of the first parameter to skip that column:
[code]
oTable.fnUpdate(['a','b','c',skip,'e'],1,0);
[/code]
I've tried a couple of different ways to no avail. Thanks for any leads. -- dmayo
I'm trying to figure out how to skip a column.
For example, this works:
[code]
oTable.fnUpdate( ['a', 'b', 'c', 'd', 'e'], 1, 0 ); // updates node=1, columns 0-4
[/code]
This is identical:
[code]
oTable.fnUpdate('a',1,0); // updates the column 0 in row 1 with value 'a'
oTable.fnUpdate('b',1,1); // updates column 1 in row 1
oTable.fnUpdate('c',1,2); // updates column 1 in row 1
oTable.fnUpdate('d',1,3); // updates column 1 in row 1
oTable.fnUpdate('e',1,4); // updates column 1 in row 1
[/code]
Is it possible to update columns 0,1,2,4 in one line of code? Not sure how I'd indicate in the array of the first parameter to skip that column:
[code]
oTable.fnUpdate(['a','b','c',skip,'e'],1,0);
[/code]
I've tried a couple of different ways to no avail. Thanks for any leads. -- dmayo
This discussion has been closed.
Replies
Allan