Question

SQL to run after Write (dynamic writer) using fme_feature_type as dynamic (table name).


Badge

After the dynamic writer is done i need to update some column for each feature type being written.

Something along the lines with (its not the actual SQL, this one is simplified for demonstration )

   
update public.$(feature_type_name) -- This is table name
set area = ST_area(geom)

I want that to be run as 

   
update public.park
set area = ST_area(geom)

But fme_feature_type is not available. Can i do this without hardcoding the feature types names?


2 replies

Badge +13

In Feature Writer > Output Ports I think you can choose Specified: (@Value(fme_feature_type) and that would allow the fme_feature_type to come out the port after dynamic writer. I hope I understand your questions correctly!

 

fme_feature_type

Badge

Yes good point, that could work. One thing I would like to do is do create/update spatial index after writing to the database. Using a duplicate filter afterward to run a single transaction on the feature type (instead of one transaction per feature).

Reply