Skip to content
This repository was archived by the owner on Jul 20, 2020. It is now read-only.
This repository was archived by the owner on Jul 20, 2020. It is now read-only.

It would be great to be able to specify the id field for GeoJSON #32

@AlexArcPy

Description

@AlexArcPy

Currently, the OID field of a feature class is used when converting the feature class to a GeoJSON. However, most often this unique ID doesn't have any meaning and it would be great to choose the field that will become the id for features in GeoJSON. When doing plotting and map bindings with such Python libraries as folium and vincent, having a meaningful id is required.

I solve this for my needs by editing the line
https://github.com/project-open-data/esri2open/blob/master/Install/esri2open/parseRow.py#L16
with the field name I want to have as id in the output GeoJSON.

replaced
self.oid=getOID(self.fields)

with
self.oid='FIELD_NAME'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions