1

in my table, I have a geometry field. I realize that there are GeometryCollection type. There are lines and polygons, it creates a lot of problems when I do processing with st_intersections. I would like to convert the GeometryCollection into polygons while keeping the polygons unique. Dots and lines should be deleted.

Here is my request:

SELECT ST_Union(ST_MakeValid(ST_SnapToGrid(wkb_geometry, 0.0001)))  ,
ST_Union(ST_MakeValid(ST_SnapToGrid(wkb_geometry, 0.0001)))::json as format_json
from public.land group by id

here is a screenshot of what i get enter image description here

Bak
  • 411
  • 1
  • 5
  • 19

0 Answers0