Table of Contents

Edit Rows

Block Group: Table Operations
Icon: Edit Rows block icon

The Edit Rows block replaces values in the input table. When the block’s trigger is invoked, rows that meet the specified criteria receive the specified value replacements. The input table must be a table that can be written to, such as the value stored by a Table block.

Caution

The Edit Rows block writes to its input table.


Input/Output Properties

The following properties of the Edit Rows block can take input and give output.

invoke causes the values to be replaced.

enabled determines whether the block is enabled.

table receives the input table in which some values will be replaced.

condition specifies the expression that determines which rows should be edited. For example, to edit the first row in the table, enter row==0. See Scripting and Syntax.

column n specifies the name of a column in the input table.

value n specifies the value to insert in column n in the input table.


Output Property

The following property of the Edit Rows block can give output but cannot take input.

print returns a string that is used for errors, other notifications, and debugging.


Example

The following images demonstrate an example of the Edit Rows block. The first image shows the table and block before invocation, and the second image shows the table and block after invocation. In this example, the values in the color column are replaced for rows where the value in the status column is “high.”

Edit Rows block example
Edit Rows block example