Optimizer estimates

RUNTIMESTATISTICS shows the optimizer estimates for a particular node. It shows the optimizer's estimated row count and the optimizer's "estimated cost."

The estimated row count is the query optimizer's estimate of the number of qualifying rows for the table or index for the entire life of the query. If the table is the inner table of a join, the estimated row count will be for all the scans of the table, not just for a single scan of the table.

The estimated cost consists of a number, which is a relative number; it does not correspond directly to any time estimate. It is not, for example, the number of milliseconds or rows. Instead, the optimizer constructs this number for each possible access path. It compares the numbers and chooses the access path with the smallest number.

Related concepts
Statistics timing
Statement execution plan
Optimizer overrides
Understanding XPLAIN style database tables