Skip to main content

I have a json file that holds coordinates in the following format:

 


How an I extract these coordinates to make the polygon that they form? I have tried reading the data through a text reader instead of a JSON reader and I have tried the JSONFragementor/JSONExtractor transformers but I can’t get the json query right, everything gets rejected.

Any ideas?​​​​​​​

Try using a geojson reader, then fme should get the geometry directly and is able to display it.

 

Afterwards (if needed) you can use a CoordinateExtractor into AttributeExposer to get the Coordinates


If the GeoJSON geometry is in an attribute, you can use the GeometryReplacer to turn it into real geometry.

But like max_h suggests, you can probably extract the geometries directly using GeoJSON in a JSON reader.