Loading...

Log Priority

A easy SQL interview practice problem on DataDriven. Write and execute real sql code with instant grading.

Domain
SQL
Difficulty
easy

Problem

The on-call rotation wants a triage view of recent server activity. For each log entry that has a recorded response time, show the server name, the original log level, the response time in milliseconds, and a triage label: logs at the CRITICAL or ERROR level should be marked urgent, everything else routine. Surface the urgent entries first, and within the same triage label, arrange by response time from slowest to fastest.

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.