Skip to main content

I'm trying to find an effective way to

  1. read in a feature class
  2. use an area on area overlayer with another feature class to split some geometries and inherit attributes
  3. update the feature class that I read in in the first place with the updated geometries and attributes

So there are two datasets, blue and red. Blue is the data I want to read in, edit and then write out. Red is the data I am going to split it by.

01_input dataI somehow want to take the blue data and edit it and then write it back out to the same feature class. In the below, the green squares are not needed as there will be no change. The orange squares in the centre will stay identical except that one of their attributes will be updated to include the "BOX_ID" of the red box (in this case, the OBJECTID) with which they intersect. The yellow squares need to be split along the boundaries of the red box, with the portion that is "inside" the box inheriting the ID of the box and the portion that is outside the box just changing geometry and keeping the BOX_ID field null.

02_data splitSee attached datasets and workspace, can anyone advise me on the best way to achieve this? The workspace I've created (created in FME Desktop 2020) does work but the fact that it reads, deletes and inserts the same feature class in a single workspace makes me a bit concerned about order of operations and getting stuck in loops when we move to larger datasets.

@bi​ you should be able to use fme_db_operation. Set this to INSERT,UPDATE,DELETE as appropriate. If you only want to update specific attributes then this article will help


@bi​  well it looks like FME can't read from a file geodatabase and then DELETE records from the same file geodatabase. I think a lock on the Data_to_split feature class must be added. To get you moving forward, I'd suggest you use the Source File Geodb as a template. That will make a copy of the dataset and then you can update that.

I've attached a copy of your modified workspace (FME 2020.2)

What version of ArcGIS or Pro are you using?


@bi​  well it looks like FME can't read from a file geodatabase and then DELETE records from the same file geodatabase. I think a lock on the Data_to_split feature class must be added. To get you moving forward, I'd suggest you use the Source File Geodb as a template. That will make a copy of the dataset and then you can update that.

I've attached a copy of your modified workspace (FME 2020.2)

What version of ArcGIS or Pro are you using?

Thanks for the advice, Mark. Weirdly, my workspace did work for me (reading and deleting) but I'm not sure that it will scale to the 60,000 rows that I have in the live data. That said, the live data are stored in an SDE, which might make the issue of the locks disappear but I'm not sure about that. I'm using 10.7.1 ArcGIS.


Reply