Expected window facts are assertions only.

highlighted = computed this step

Honest by construction

Expected window facts are assertions only.

compiler is source of truth\text{compiler is source of truth}

Render checked facts

The guarded example renders 2 rows after recomputation.

checked rows=2\text{checked rows}=2

Window-function examples are tiny finite table transforms; SQL dialects, NULL ordering, frames beyond prefix rows, optimizer behavior, performance, and product behavior are out of scope.

Honest by construction: base rowsidregiondaynote1NULL1held2NULL2ready partitionspartitionKeysourceRowsrowCount[NULL][0, 1]2 window rowssourceRowpartitionKeyorderKeytieBreakerKeyrowNumber0[NULL][1][1]11[NULL][2][2]2 ambiguous tiespartitionKeydeterministicKeysourceRowsnonenonenone window factsfactvaluerowCount2partitionCount1partitionColumnsregionorderColumnsdaytieBreakerColumnsidfunctionsrow_numberresultRowCount2rejectednorejectionReasonnoneambiguousTieGroups0rowOrderpartition_then_orderframenone

Try to tamper

Wrong expected facts, derived sidecars, unsupported functions, bools, floats, and missing columns fail closed.

tamper rejected\text{tamper rejected}

Summary

The book shows finite window behavior only; product SQL behavior is outside the model.

scoped window model\text{scoped window model}