Add Column using ECQL expressions

Add to WKT (Well-known Text) geometries a column computed using the Contextual Query Language

When your expression returns a numeric, Boolean or String result, you have to define the type of the column into which this results will be stored and the name of this column. If your expression returns a geometry, you can either process it as a geometry, and replace the original geometry; or store it as a String into a novel column.

Examples of queries:

  • compute the area: "area(the_geom)"
  • compute a centroid: "centroid(the_geom)"
  • compute a buffer: "buffer(the_geom, 10)"
  • compute the distance to a point defined by flow two Double flow variables x and y: "distance(the_geom,$${Dx}}$,$${Dy}}$)"
More examples can be found here: Geoserver ECQL Tutorial

Note that the units used in the query depend on the Coordinate Reference System.

The actual processing is done by the awesome geotools library.


The query in Contextual Query Language
The type of the column to create. Ensure it is consistent with the result of the query
The name of the column to create

Input Ports

Entities with spatial features

Output Ports

The entities with the computation result


This node has no views




You want to see the source code for this node? Click the following button and we’ll use our super-powers to find it for you.