Nested loop work is a visible integer formula.

highlighted = computed this step

Nested loop work units

In this toy model, nested loop compares every filtered left row with every right row.

filtered left×right\text{filtered left}\times\text{right}

Multiply the counts

The model uses 3 filtered rows and 8 right rows to estimate 24 work units.

nested loop work=24\text{nested loop work}=24

Optimizer-choice examples are named toy estimate-model outputs; they are not benchmark results, database-product claims, hardware claims, or real speed predictions.

Nested loop work units: table statstablerolerowCountdistinctKeysOrdersleft_after_filter_input126Customersright_join_input88 filter estimatelabelinputRowsselectivityestimatedRowsstatus filter121/43 plan estimate rowsplanformulaleft/buildright/probeestimatedWorkchosennested_loop_joinfiltered_left_rows * right_rows3824nohash_joinbuild_rows + probe_rows8311yes estimate factsfactvaluemodelNametoy_optimizer_estimate_v1leftRows12rightRows8selectivity1/4filteredRows3nestedLoopWork24hashJoinWork11chosenPlanhash_joinrealSpeedClaimnoproductClaimnorequiresBenchmarkForSpeedyes

Read the formula row

The plan estimate table shows the formula beside the computed work units.

formula is visible\text{formula is visible}

Summary

Work units are model tokens; they are not wall-clock time.

not real time\text{not real time}