โ† NielsenIQ questions
CodingReported in a candidate post, Sep 2025

Longest trip per vehicle by time on the road

Filed under NielsenIQ

The question

Given a trips table (trip id, vehicle id, start time, end time, distance in km), write a SQL query that finds, for each vehicle, the trip that took the longest time on the road.

No write-up yet. Related questions below have one.

Related NielsenIQ questions

Collected from public candidate posts and coding forums. Updated Nov 2026.