#7194 closed defect (fixed)
ogr2ogr does not preserve fid in geojson when specify RFC7946=YES
Reported by: | jingsam | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | 2.2.4 |
Component: | default | Version: | 2.2.3 |
Severity: | normal | Keywords: | |
Cc: |
Description
I tried to covert a shapefile to geojson:
ogr2ogr -f GeoJSON a.geojson a.shp -preserve_fid -lco RFC7946=YES
In converted geojson, "id" is missing.
But I use following command, everthing works as expected.
ogr2ogr -f GeoJSON a.geojson a.shp -preserve_fid
RFC7946 says:
If a Feature has a commonly used identifier, that identifier SHOULD be included as a member of the Feature object with the name "id", and the value of this member is either a JSON string or number.
Note:
See TracTickets
for help on using tickets.
This issue has some connection with #6538