Codington
0 of 8 problems solved • 0%

Exercise prompt

Find the Timing Range for Each Service ID

You can group directly on the foreign key in the log. Rows whose service_id is NULL form a group of their own. MIN and MAX use the recorded durations within each group.

Your task

From deployments, return service_id, the shortest recorded duration as min_seconds and the longest as max_seconds. Include the group of unassigned runs and groups with no measured time.

Opening the database…