ogr2ogr PG driver doesn't properly set track_points::track_fid
|Reported by:||wstrzalka||Owned by:||warmerdam|
track_points::track_fid is in no relation to tracks::ogc_fid which is it's parent record.
After importing large gpx file to empty database the result of the following query is:
SELECT COUNT(track_fid) FROM track_points AS tp LEFT JOIN tracks AS t ON (tp.track_fid=t.ogc_fid) WHERE t.ogc_fid IS NULL;
While the doc says:
In addition to its GPX attributes, each route point of a route has a route_fid (foreign key to the FID of its belonging route) and a route_point_id which is its sequence number in the route. The same applies for track points with track_fid, track_seg_id and track_seg_point_id.
Of course trying to set an FK there ends with failure.