StopFetching
Mon 01 January 2018Syntax
StopFetching()
Description
The StopFetching function is called during Row Select processing, during which rows of data that have been selected down from the database can be filtered as they are added to the component. This function is valid only in RowSelect PeopleCode. If StopFetching is called without DiscardRow, it adds the current row to the component, then stops adding any more rows. If StopFetching is called with DiscardRow, the system skips the current row and stops adding rows to the component.
StopFetching has the same functionality as the Error function in the RowSelect event. The anomalous behavior of Error is supported for compatibility with previous releases of PeopleTools.
Note: Row Select processing is used infrequently, because it is more efficient to filter out rows of data using a search view or an effective-dated record before the rows are selected down to the client from the database server.
In row select processing, the following actions occur:
-
The Component Processor checks for more rows to add to the component.
-
The Component Processor initiates the RowSelect event, which triggers any RowSelect PeopleCode associated with the record field or component record.
This enables PeopleCode to filter rows using the StopFetching and DiscardRow functions. StopFetching causes the system to add the current row to the component, and then to stop adding rows to the component. DiscardRow filters out a current row, and then continues the row select process.
-
If neither the StopFetching nor DiscardRow function is called, the Component Processor adds the rows to the page and checks for the next row.
The process continues until there are no more rows to add to the component buffers. If both StopFetching and DiscardRow are called, the current row is not added to the page, and no more rows are added to the page.
Image: Row Select Processing Logic
The following flowchart shows this row select processing logic:

Returns
None.