An apparatus, program product and method that employ a dynamic use of Look
Ahead Predicate Generation that will enable the database, database
engine, and/or query optimizer to alter the processing of a query, and
react to sub-optimal access plan selection and additional factors arising
after processing has begun, to heal many poor performing queries.
Conventional use of LPG requires the query optimizer to decide whether or
not to use LPG before the processing of a query begins. As a result, the
query optimizer may not only make sub-optimal decisions, but the query
optimizer may not consider additional factors that may arise as the query
is processing. However, the dynamic use of LPG allows predicates to be
built after processing of the query has started and the ability to alter
the query's processing to improve query performance.