Field calculator & SQL
Compute and update columns with the field calculator, and run full SQL — including spatial functions — in the SQL console.
DropMaps runs DuckDB in your browser, so you can compute new columns and query your data with real SQL — no server, nothing uploaded.
Field calculator
Open Field calc from the attribute table. It fills or updates a column from an expression.
- Target — update an Existing field, or create a New column (with a name and type).
- Scope — apply to All features, or just the current Selected features.
- Expression — reference columns with
{field}tokens, e.g.{area} / 10000for hectares. Show SQL reveals the fullUPDATEstatement being run. - Function buttons insert ready-made functions grouped by Text (UPPER, TRIM, CONCAT, SUBSTR…), Math (ROUND, ABS, POWER…), Logic (CASE WHEN, COALESCE…), Convert (CAST), Date (CURRENT_DATE, strftime…), and Spatial (ST_Area, ST_Length, ST_Centroid, ST_X/Y…).
- Preview shows sample before/after values; Calculate applies the change.
SQL console
For anything beyond a single column, open the SQL console for full read/write SQL across all your layers and tables.
Schema & snippets
A sidebar lists each layer/table and its columns — click to insert names into the editor. Every
spatial layer exposes a geom column (lon/lat) and geom_m (metres) for distance/area work.
Snippets drop in starting points: Preview a layer, Join two layers, Spatial overlay → layer,
Buffer → layer, Dissolve → layer, Count by category, Points in polygons, and more.
Run & create layers
- Run executes a read query and shows the results.
- If a result has a
geomcolumn, name it and select Create layer to drop the query straight onto the map as a new, styleable, exportable layer. - Write statements (
UPDATE/DELETE/ DDL) run under Run (writes) — flagged as a danger action because they can’t be undone.
Function reference
A built-in, expandable reference covers text, math, logic, conversion, date, aggregate and window functions, plus the spatial set: ST_Intersection, ST_Intersects, ST_Contains, ST_Within, ST_Buffer, ST_Union_Agg, ST_Centroid, ST_Area, ST_Length, ST_Distance, ST_X/Y, ST_AsGeoJSON and more.
Everything runs client-side — your data never leaves the browser.
Next steps
- The attribute table — where the field calculator lives.
- Spatial analysis — point-and-click versions of common spatial ops.
- Charts — visualise query results.