IniziaInizia gratis

Completion time by category

The evanston311 data includes a date_created timestamp from when each request was created and a date_completed timestamp for when it was completed. The difference between these tells us how long a request was open.

Which category of Evanston 311 requests takes the longest to complete?

Questo esercizio fa parte del corso

Exploratory Data Analysis in SQL

Visualizza il corso

Istruzioni dell'esercizio

  • Compute the average difference between the completion timestamp and the creation timestamp by category.
  • Order the results with the largest average time to complete the request first.

Esercizio pratico interattivo

Prova a risolvere questo esercizio completando il codice di esempio.

-- Select the category and the average completion time by category
SELECT ___, 
       ___ AS completion_time
  FROM evanston311
 ___
-- Order the results
 ___;
Modifica ed esegui il codice