Skip to main content
I have a workspace that compares a PATH HIERARCHY data set attribute of video file names to a GeoMedia Feature data set attribute of sewer segment names and does a feature merger on the two datasets when there is a match.  Sewers are usually videod from upstream to downstream and the video files are named according to the direction in which the camera was travelling.  My workspace gets quite a few matches BUT...there are occasions where the videos are named from downstream to upstream which causes my feature merger to send that video name to the incomplete branch.  I would like to parse the video name attribute and use the result to create a new attribute that is the reverse.  So 'MH07-121 to MH07-122' would become 'MH07-122 to MH07-121' in the new attribute.   Could someone please suggest an approach that would accomplish this for me?   Thanks.
Hi,

 

 

I would parse the attribute value with a regular expression = string searcher and reconcatenate the matching parts (string concatenator) to form the new value.

 

 

Hope this helps.
As always there are more than one way to do things in FME, so if you value is separated by ' to' you can use that as the delimeter value in the attribute splitter   and then reconcatenate the list values. 
Yes, there should be some approaches.

 

I would use StringSearcher, Tester and StringReplacer.

 

 

Takashi

Reply