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}}$)"
Note that the units used in the query depend on the Coordinate Reference System.
The actual processing is done by the awesome geotools library .