Published
Edited
Aug 19, 2022
1 fork
12 stars
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
db
select * from snapshots;
Insert cell
Insert cell
db
select
snapshots.rowid,
vehicles.value
from snapshots
join json_each(snapshots.response_body, '$.Vehicles') as vehicles
Insert cell
Insert cell
db
select
json_extract(value, '$.BlockFareboxId') as block_farebox_id,
json_extract(value, '$.CommStatus') as comm_status,
json_extract(value, '$.Destination') as destination,
json_extract(value, '$.Deviation') as deviation,
json_extract(value, '$.Direction') as direction,
json_extract(value, '$.DirectionLong') as direction_long,
json_extract(value, '$.DisplayStatus') as display_status,
json_extract(value, '$.StopId') as stop_id,
json_extract(value, '$.CurrentStatus') as current_status,
json_extract(value, '$.DriverName') as driver_name,
json_extract(value, '$.GPSStatus') as gps_status,
json_extract(value, '$.Heading') as heading,
json_extract(value, '$.LastStop') as last_stop,
json_extract(value, '$.LastUpdated') as last_updated,
json_extract(value, '$.Latitude') as latitude,
json_extract(value, '$.Longitude') as longitude,
json_extract(value, '$.Name') as name,
json_extract(value, '$.OccupancyStatus') as occupancy_status,
json_extract(value, '$.OnBoard') as on_board,
json_extract(value, '$.OpStatus') as op_status,
json_extract(value, '$.RouteId') as route_id,
json_extract(value, '$.RunId') as run_id,
json_extract(value, '$.Speed') as speed,
json_extract(value, '$.TripId') as trip_id,
json_extract(value, '$.VehicleId') as vehicle_id,
json_extract(value, '$.SeatingCapacity') as seating_capacity,
json_extract(value, '$.TotalCapacity') as total_capacity,
json_extract(value, '$.PropertyName') as property_name,
json_extract(value, '$.OccupancyStatusReportLabel') as occupancy_status_report_label
from snapshots
join json_each(snapshots.response_body, '$.Vehicles')
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
db
select * from failed_banks;
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
db
select
carmack_plans.*,
rank
from fts_carmack_plans('teleport')
left join carmack_plans on carmack_plans.rowid = fts_carmack_plans.rowid
order by rank
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
import { DatasetteClient } from "@ambassadors/datasette-client"
Insert cell
db = new DatasetteClient("https://sqlite-extension-examples.fly.dev/data")
Insert cell
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more