SETEOF Function

Sets status to end of file (EOF), preventing further rows from being read in the step. If the parameter is true, the pushed rows are still returned.

Category: Data Input
Returned data type: Integer
Note: The returned value is a Boolean value where 1= success and 0 = error.

Syntax

SETEOF(<return_pushrow>)

Optional Argument

return_pushrow

Boolean value; to specify whether pushed rows are still returned

Details

When SETEOF() is called, the node does not read any more rows from the parent node. If generate rows when no parent is specified is checked, the node stops generating rows. Furthermore, if any rows have been pushed using PUSHROW(), they are discarded, and further calls to PUSHROW() have no effect. The exception to this is if SETEOF(true) is called. In this case, any pushed rows (whether pushed before or after the call to SETEOF() are still returned to the node below. Notably, if further PUSHROW() calls occur after SETEOF(true) is called, these rows are returned as well. Also note that after SETEOF() is called, the post-group expression and the post expression are still executed.

Example

seteof()