A place to start
Query data with confidence
A query can return plausible numbers and still answer the wrong question. Start with the result grain, make ordering and window frames explicit, and inspect the plan before adding an index. For concurrent writes, work through the anomaly your transaction must prevent.