  The WHERE and ORDER BY clauses of the SQL SELECT statement select a subset of
rows in the result of a database query and present the result in the specified
order. In a spreadsheet program like Microsoft Excel, one could use the filter
and sort buttons, or use its Query or its Pivot Table tools to achieve a
similar effect. The disadvantage of using those tools is that they don't react
automatically to changes in the calculated values of the spreadsheet. In this
paper, we develop spreadsheet formulas that implement SQL's WHERE and ORDER BY
clauses.
