GeoLabSpatial SQL Workbench
Capability guide

GeoJSON SQL Query Tool

GeoLab imports .geojson and .json files through DuckDB Spatial's ST_Read, exposes the result as a named relation, and treats the geometry as EPSG:4326 for browser map display.

Input
.geojson or .json
Reader
DuckDB Spatial ST_Read
CRS
Treated as EPSG:4326
Output
Map layer or table preview

From file to SQL relation

  • The file is registered with DuckDB-WASM in the current browser session.
  • ST_Read creates a local table and GeoLab normalizes the native geometry column name when needed.
  • The source name becomes the SQL relation name after unsafe filename characters are normalized.
  • Queries that retain recognizable geometry render on the map; attribute-only queries open as a table preview.

Example: find the polygon containing a point

Query the built-in districts relationsql
SELECT
  id,
  name,
  geometry
FROM districts
WHERE ST_Contains(
  geometry,
  ST_Point(-0.100, 51.520)
);

NoteFor the built-in demo data, this returns the North Market polygon and keeps its geometry available for rendering.

Spatial and non-spatial results

Selecting geometry allows GeoLab to classify and render the result. Selecting only id and name is still valid SQL, but the result has no recognizable geometry and is shown as a table instead of a map layer.

Query resultGeoLab presentation
Contains a native GEOMETRY columnPoint, line, polygon, multi-geometry, or collection layer
Contains WKT or known coordinate pairsDetected spatial layer
Contains attributes onlyUp to 200 preview rows

Current input boundary

  • GeoLab v0.1.0 does not expose Shapefile, GeoPackage, KML, or Parquet in the file picker.
  • GeoJSON is treated as WGS84; coordinate transformation is explicit SQL, not an automatic import step.
  • The interface queries and visualizes features but does not provide geometry editing or file export.

Sources and scope

These links document the product behavior summarized above. GeoLab-specific claims are limited to the current public v0.1.0 implementation.

  1. GeoLab DuckDB adapterImplemented CSV/GeoJSON import and query-result detection.
  2. DuckDB spatial data sourcesOfficial GDAL-backed spatial input documentation.
  3. DuckDB Spatial functionsOfficial reference for geometry constructors, predicates, and measurements.