id summary reporter owner description type status priority milestone component version severity resolution keywords cc 7057 Auto-enabled paging of ArcGIS REST may give corrupted data Jukka Rahkonen warmerdam "As explained in http://www.gdal.org/drv_geojson.html GDAL enables automatically paging if ArcGIS REST server that requires. However, current implementation may lead to corrupted data as in gis.stackexchange question https://gis.stackexchange.com/questions/256668/ogr2ogr-get-geojson-from-map-server-misses-features-and-creates-duplicates The error comes from wrong assumption that the n features that server returns if query is made without ""resultRecordCount"" and ""resultOffset"" parameters, where n is the server side setting for maximum resultRecordCount, are the same n features which are returned by having {{{ resultRecordCount=n&resultOffset=0 }}} That is not necessarily the case but server may sort features differently if paging parameters are provided or not. The safe way would be to check the server side resultRecordCount limit and query also the first page with explicit record count and offset. Because GDAL may turn paging on automatically data corruption may happen without user notising it even there are ways to avoid that with some GDAL parameters https://lists.osgeo.org/pipermail/gdal-dev/2017-September/047230.html. " defect closed normal closed_because_of_github_migration default unspecified normal wontfix