I am stuck with the problem of updating a table in geopackage.
I am reading excel records which have a unique Excel_ID number. Then, after some transformers I write the result in a geopackage non spatial table with the primary index column FID set in writer's parameters. Also I track changes with the Change Detector based on Excel_ID field, where the Original features is destination geopackage table and the Revised is the excel table.
Further, if I try to write updatet rows in geopackage table with the selected Excel_ID as the ID attribute of the Row selection of a writer parameters, I get an error since the Excel ID is compared with the geopackage FID, which, of course, are different.
Then I tried using Feature Merger to combine the updated excel rows with the record from the geopackage table to attach geopackage_fid to the rows join on Excel_ID field. ID attribute of the Row selection of a writer parameters I set to geopackage_fid.
However, this time some of the features are successfully writes to the destination , and some are rejected with the GEOPACKAGE writer error:
"Cannot perform Update on feature type "ABC" because feature with ID '555' does not exist. Skipping features"
despite the fact that features with this FID are in the table. In the inspector - the updated features also look quite correct. Perhaps the problem is in the order of the records to be written, however, I tried to apply some Sorters and FeatureHolders which did not bring results.
Any idea why this error appears?
I would really appreciate for help!
Let me know if description looks unclear and I'll attach the workspace.