6

I have a shapefile with points and different attributes - one attribute MyID. I also have a plain text file with several attributes - each in a separated column:

MyID MyValue
 1    A
 2    B
 3    C
 :    :

I would like to use FME to append my attributes in the text file using the attribute key/value MyID.

Is this possible, and in that case how?

  • GIS-Jonathan got the post in first... Mapperz was 6mins behind. – Mapperz Apr 24 '12 at 13:42
4

The Feature Merger transformer will allow you to Join by attributes

enter image description here Using FME Desktop 2012 SP2 here

http://docs.safe.com/fme/pdf/FMEReadersWriters.pdf

Search 'Feature Merger'

A good blog post 'Joiner vs Feature Merger' by Mark Ireland

http://evangelism.safe.com/fmeevangelist79/

  • For very large datasets (I tested 4+ million features) the Joiner is much faster (i.e. 1hr 45 versus 3hrs). But generally speaking the FeatureMerger is easier to use. – GIS-Jonathan Apr 24 '12 at 13:54
4

This can be done easily in a number of ways, but the best way would be to use the FeatureMerger Transformer.

The Requestor will be the shapefile, the Supplier will be the text file. If you leave the settings on their defaults that should be fine for you. This will give you parameters that look like this:

enter image description here

Note: The first few times you run it be sure to connect visualisers/inspectors to _all_output ports for the FeatureMerger. This way you'll be able to see what does/doesn't match.

The output of the "complete" port will have the merged features in the way you want.

2

Have a look at inlinequerier ,it deserves your attention for the future when you need to chain multiple featuremergers , it creates indexes in a smarter way and speedsup your translations. Inlinequerier ... have a look.

Jorge Vidinha

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.