A database system and method provide support for a positioned data set
modification operation on a collection of data sets involved in a data set
query operation, in which the data set modification operation is based on
the position of a query execution iterator. At query compile time, the
database system generates an iterator position retrieval function and a
data set modification function for each data set involved in the query
operation. At query execution time, the database system invokes each of
the iterator retrieval functions until the iterator position retrieval
function for a current open data set returns the current the position of
the query execution iterator on that data set. The database system then
invokes each of the data set modification functions until the data set
modification function for the current open data set performs a data set
modification operation at the current position of the query execution
iterator specified by the iterator position retrieval function. The system
and method may be implemented on single node systems and on multi-node
shared-nothing parallelism architectures.