Skip to main content
Solved

Inserting Disclaimers/Metadata into Zipped Folders


dmerrick
Contributor
Forum|alt.badge.img+1

Hi,

I am trying to figure out how to insert disclaimers/metadata from one folder to all zipped folders within another folder?

 

 

My setup involves Reading from an SDE connection, an InlineQuerier transformer to definition query various private data fields out of the data, an Attribute Keeper transformer to keep only the pertinent fields for public viewing before 6 different writers take the data and convert and zip to file geodatabase, kml, shapefile, AutoCAD, CSV, and GeoPackage. With each feature class/dataset being converted into 6 different formats into a single export folder. The naming convention will be standardized (Parks_KML.zip, Addresses_shp.zip, Water_FGDB.zip etc), I need to insert a text disclaimer file into each of the zipped folders.

 

I thought using the FileCopy Writer from this example (https://knowledge.safe.com/articles/881/including-additional-files-in-the-data-download-re.html)

with a wildcard fanout of the export folder but I am unable to make that work.

 

 

Thanks!

 

@takashi

Best answer by takashi

Hi @dmerrick, if you write the six zip archives with FeatureWriters, it would be quite easy to insert a common metadata file into them with another FeatureWriter (File Copy writer).

This is just a mock-up, but I think you can apply this technique to the actual workspace. Assuming that the value of user parameter called "METADATA_FILE" indicates the file path to the metadata.

View original
Did this help you find an answer to your question?

6 replies

takashi
Contributor
Forum|alt.badge.img+19
  • Contributor
  • Best Answer
  • May 25, 2018

Hi @dmerrick, if you write the six zip archives with FeatureWriters, it would be quite easy to insert a common metadata file into them with another FeatureWriter (File Copy writer).

This is just a mock-up, but I think you can apply this technique to the actual workspace. Assuming that the value of user parameter called "METADATA_FILE" indicates the file path to the metadata.


dmerrick
Contributor
Forum|alt.badge.img+1
  • Author
  • Contributor
  • May 29, 2018
takashi wrote:

Hi @dmerrick, if you write the six zip archives with FeatureWriters, it would be quite easy to insert a common metadata file into them with another FeatureWriter (File Copy writer).

This is just a mock-up, but I think you can apply this technique to the actual workspace. Assuming that the value of user parameter called "METADATA_FILE" indicates the file path to the metadata.

Thanks @takashi, the transformer keeps on failing with the error "Cannot have multiple factories with the same name. Multiple Factories were assigned the name '#######'"

 

I am not sure what I have done that is incorrect?

 


fmedon
Contributor
Forum|alt.badge.img
  • Contributor
  • August 13, 2018
I am having the same issue as well with the error

 

'Cannot have multiple factories with the same name. Multiple factories were assigned the name filecopy_FileCopy_1988b768_ee88_46d6_a4a5_af7e9f06e5481'

 

If I only have 1 featurewriter going to the FileCopy FeatureWriter the transformer works. But every other time it does not. Thanks!

xiaomengatsafe
Safer
Forum|alt.badge.img+3
fmedon wrote:
I am having the same issue as well with the error

 

'Cannot have multiple factories with the same name. Multiple factories were assigned the name filecopy_FileCopy_1988b768_ee88_46d6_a4a5_af7e9f06e5481'

 

If I only have 1 featurewriter going to the FileCopy FeatureWriter the transformer works. But every other time it does not. Thanks!
Hi @fmedon, can you tell us what version of FME are you using?

 


xiaomengatsafe
Safer
Forum|alt.badge.img+3
xiaomengatsafe wrote:
Hi @fmedon, can you tell us what version of FME are you using?

 

The issue you reported is very similar to a bug we recently fixed. If you are using fme 2018.0 a build before b18295 (or linux build 18447), can you install the latest FME release and see if the problem goes away? Thank you!

 

 


fmedon
Contributor
Forum|alt.badge.img
  • Contributor
  • August 16, 2018
xiaomengatsafe wrote:
Hi @fmedon, can you tell us what version of FME are you using?

 

Hi! Thank you for the reply I will try the latest version... Thanks!

 

 


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings