Skip to main content
Released

Add option for whether to ignore leading and trailing spaces in transformers tha

Related products:FME Form
  • October 13, 2017
  • 2 replies
  • 5 views

fmelizard
Safer
Forum|alt.badge.img+21

***Note from Migration:***

Original Title was: Add option for whether to ignore leading and trailing spaces in transformers that matches attribute values


In FME there are a lot of transformers that compares values of attributes, as part of their function. e.g. FeatureMerger, Matcher, DuplicateFilter, etc.
These transformers don't all behave consistently, when it comes to whether they ignore the leading and training spaces.
For example FeatureMerger will consider values "a", " a", and " a " the same, in matching key attributes; While DuplicateFilter will consider these values different from one another.

It would be nice to add an option, which allow users to specify whether these spaces should be ignored or not.

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

2 replies

Forum|alt.badge.img+6

UGH! I thought it was buggy behavior and filed a case, then was pointed to this link. I would prefer to have all transformers behave consistently and not try to do things without user knowledge. Those can then be exposed as options. The transformers that led me to understand that they were doing something with trailing spaces were the SchemaMapper and FeatureMerger. In the case of the SchemaMapper, the built-in behavior was actually NOT desireable and was causing issues in the end result.


ebygomm
Influencer
Forum|alt.badge.img+46
  • Influencer
  • August 30, 2019

Yes, I had a featuremerger followed by a group by and the feature merger ignores the trailing space whilst the group by does not leading to erroneous results. I've ended up adding a string length test to my featuremergers to ensure leading/trailing spaces are not considered matches.