[gdal-dev] Problem with OAPIF and numeric id in the data
Rahkonen Jukka (MML)
jukka.rahkonen at maanmittauslaitos.fi
Mon Jun 21 12:20:08 PDT 2021
Even Rouault <even.rouault at spatialys.com> wrote:
>> However, QGIS seems to drop the native fids and generate new ones but that's another problem to learn to circumvent.
> Hum, I'm afraid it will not be easy. The QGIS WFS / OAPIF provider stores internally the feature id in the
> internal feature cache but doesn't expose it. The QGIS feature id you get from such layer is a purely
> synthetical one, and that may change between sessions. Trying to remember about that design choice,
> there are several reasons:
* if the WFS layer is a result of a join operation, there is no unique id
* if we exposed the gml:id (or JSON id) as a regular field, that could cause issues for transactional WFS support where you don't want users to modify that value
In that case I think we must publish the id two times in the OAPIF service, once as the id member and another time as "landmark_id" or something in the feature properties because the id is meaningful for the users. They must be able to search by landmark_id and show them on the map.
> That could probably be changed pending some work.
-Jukka-
> Even
--
http://www.spatialys.com
My software is free, but my time generally not.
More information about the gdal-dev
mailing list