SQL console
Query every table from your browser at transitlab.nyc/sql. Nothing to install.
The SQL console runs DuckDB inside your browser tab, with the transitlab database already attached. Type a query, run it, and see the result as a table.
It is the quickest way to look around: check a table’s columns, try a filter, or copy a result into a spreadsheet.
Things to try
Section titled “Things to try”-- Every table and its columnsSHOW ALL TABLES;
-- The slowest bus routes in our latest week of dataSELECT route_id, round(sum(meters) / sum(seconds) * 2.23694, 2) AS mphFROM transitlab.bus_route_speedsWHERE service_date::DATE >= (SELECT max(service_date)::DATE - 7 FROM transitlab.bus_route_speeds)GROUP BY route_idHAVING sum(trips) >= 50ORDER BY mphLIMIT 15;Limits
Section titled “Limits”Your browser does the work, so it has your browser’s memory. Queries over small tables and single months of trips run well. For years of trips, use DuckDB on your own machine; the SQL is the same.