Skip to main content

Hi,

 

I have a workspace that truncates an SDE geometry table and refills it. The workspace runs daily and sometimes there are no records to write. In that case the writer only has to truncate the table. I don't see an option truncate first or anything like that in a sde writer.

How can I truncate a table while the writer is empty?

 

 

For this sort of scenario, I'd truncate the tables using an sqlexecutor upstream of the writers to ensure all tables are truncated.


Thanks. Now I use a creator followed by a sqlexecuter. This works.


In my case I'd like to truncate the table (FGDB feature class) that is in the Reader, after the table has been read. Is that possible?


I do not know. i never truncated right after the reader. I have to test it.


An SQLExecutor downstream of the Reader should do the trick.

Note that one SQL query is issued for each feature that enters the transformer. So do make sure only one feature enters the SQLExecutor!

Maybe use a Sampler (sample the last feature!), or the combination of a Creator and a FeatureReader.

Trigger_SQLExecutor


Thanks, i will try this.


Reply