Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Support feature id of geojsons and topojsons #11

Open
sraimund opened this issue Aug 4, 2021 · 0 comments
Open

Support feature id of geojsons and topojsons #11

sraimund opened this issue Aug 4, 2021 · 0 comments

Comments

@sraimund
Copy link

sraimund commented Aug 4, 2021

Thank you for developing this practical tool!

It would be nice if the feature id of geojsons and topojsons would be also recognized as a column. See the last bullet point of section 3.2 in the geojson specification for further details: https://datatracker.ietf.org/doc/html/rfc7946#section-3.2

Here an exemplary geojson file for testing:

{
  "type": "FeatureCollection",
  "name": "switzerland",
  "features": [{
      "type": "Feature",
      "id": "CH",
      "geometry": {
        "type": "Polygon",
        "coordinates": [[[8.558133691490156, 47.807404569040386], [10.403686252119602, 46.639241157337544], [7.098859573783153, 45.860465549535654], [6.111703552981356, 46.580832986752405], [8.558133691490156, 47.807404569040386]]]
      }
    }
  ]
}

Currently no column is recognized when the file is uploaded to the Geo Data Merger. The same applies for topojsons like this:

{
  "type": "Topology",
  "arcs": [[[57, 100], [43, -60], [-77, -40], [-23, 37], [57, 63]]],
  "transform": {
    "scale": [0.042919826991382456, 0.019469390195047325],
    "translate": [6.111703552981356, 45.860465549535654]
  },
  "objects": {
    "country": {
      "type": "GeometryCollection",
      "geometries": [{
          "arcs": [[0]],
          "type": "Polygon",
          "id": "CH"
        }
      ]
    }
  }
}

Supporting this case would save the user an additional conversion step, namely including the "id" in the properties of a feature. Often ids are used for joining.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant