Skip to main content
Pentaho Documentation

Understanding Row Counters

During transformation execution, each PDI step keeps track of a set of step metrics. These are displayed in Spoon in the Step Metrics tab.

csvInputErrorLogging.png
 

Each step metric is essentially a row counter. The counters are manipulated by calling the corresponding increment, decrement, get, and set methods on BaseStep. This table provides a list of the counters and the correct way to use them. 

Counter Name Meaning When to Increment
linesRead Rows received from previous steps Never increment manually. This is handled by getRow().
linesWritten Rows passed to next steps Never increment manually. This is handled by putRow().
linesInput Rows read from external sources, such as files, database, and alike Call incrementLinesInput() when a new row is received from an external source.
linesOutput Rows written to external sources, such as files, database, and alike Call incrementLinesOutput() when a row is written to an external system or file.
linesUpdated Rows updated in external sources, such as database, and alike Call incrementLinesUpdated() when a row is updated in an external system or file.
linesSkipped Rows for which part of the processing has been skipped Call incrementLinesSkipped() when a row was skipped. This is relevant when the step implements conditional processing, and the condition for processing a row is not satisfied. For example, an updating step may skip rows that are already up to date.
linesRejected Rows diverted to an error step as part of error handling Never increment manually. This is handled by putError().