Loading...
Smooth Latency
A medium SQL interview practice problem on DataDriven. Write and execute real sql code with instant grading.
- Domain
- SQL
- Difficulty
- medium
Problem
The SRE team wants to spot latency trends per endpoint over time. For every row in api_calls with a non-NULL latency, compute a running average of latency within that endpoint ordered by call_time, covering every call at or before this one. Return the endpoint, latency, and running average.
Practice This Problem
Solve this SQL problem with real code execution. DataDriven runs your SQL queries against a live PostgreSQL database and grades it instantly.