Skip to content

Instantly share code, notes, and snippets.

@thorwebdev
Created December 15, 2014 20:34
Show Gist options
  • Save thorwebdev/c5b483737f52cafcfa76 to your computer and use it in GitHub Desktop.
Save thorwebdev/c5b483737f52cafcfa76 to your computer and use it in GitHub Desktop.
Calculate the number of trips that started in a certain area.
SELECT
pickup_polyId,
COUNT(*) AS no_of_trips
FROM
[nyctaximap:dataflow.nyc_output_join_fare_distinct]
GROUP BY
pickup_polyId
ORDER BY
no_of_trips DESC;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment