Skip to main content
Solved

Concatenate fields with space in between


nikkik
Contributor
Forum|alt.badge.img+6

I am trying to concatenate 6-7 fields to create single field with spaces in-between different field values to create a address like string, no commas needed. Can I do it in text editor?

             Field1  Field2  Field3 

original: 123     ABC      Street 

                  Filed Combined 

 Target:    123 ABC Street 

Best answer by alexbiz

StringReplacer should help clean that up : 

Don’t forget to type a space character in the replacement text parameter of the StringReplacer

View original
Did this help you find an answer to your question?
This post is closed to further activity.
It may be a question with a best answer, an implemented idea, or just a post needing no comment.
If you have a follow-up or related question, 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.

12 replies

crutledge
Influencer
Forum|alt.badge.img+33
  • Influencer
  • May 12, 2025

Hi ​@nikkik I think in your case the Aggregator will work well.
 

 


crutledge
Influencer
Forum|alt.badge.img+33
  • Influencer
  • May 12, 2025

And it would be silly not to recommend the StringConcatenator.😆

 


nikkik
Contributor
Forum|alt.badge.img+6
  • Author
  • Contributor
  • May 14, 2025

I am using String concatenator but it doesn’t place space between different fields it comes as one string like

123ABCStreet

Thanks!


takashi
Influencer
  • May 14, 2025

If you are using the StringConcatenator with Basic mode, you can select “Constant” in the String Type column to insert any character(s) including a space literally.

 


alexbiz
Enthusiast
Forum|alt.badge.img+12
  • Enthusiast
  • May 14, 2025

I personally wouldn't bother with the StringConcatenator. You can just use an AttributeCreator for this :

 

 


nikkik
Contributor
Forum|alt.badge.img+6
  • Author
  • Contributor
  • May 14, 2025

issue i am facing is there are nulls in some fields and i am getting unnecessary space in-between how do i solve it so the final field values comes correctly. example below. lots of space between number and street name because field between them have null. 

 

 

 


alexbiz
Enthusiast
Forum|alt.badge.img+12
  • Enthusiast
  • Best Answer
  • May 14, 2025

StringReplacer should help clean that up : 

Don’t forget to type a space character in the replacement text parameter of the StringReplacer


nikkik
Contributor
Forum|alt.badge.img+6
  • Author
  • Contributor
  • May 21, 2025

it is removing all the spaces and not just extra.

Thanks!

 


alexbiz
Enthusiast
Forum|alt.badge.img+12
  • Enthusiast
  • May 21, 2025
alexbiz wrote:

Don’t forget to type a space character in the replacement text parameter of the StringReplacer

;)


raghavendrans
Enthusiast
Forum|alt.badge.img+14

@nikkik 

May be you should consider cleaning up your data using the NullAttributeMapper before sending it or doing the String Concatenation!

Happy FME:-) ing

Cheers

SRG


alexbiz
Enthusiast
Forum|alt.badge.img+12
  • Enthusiast
  • May 21, 2025

@raghavendrans Unfortunately this will do nothing, since the spaces are not values of the attributes.


nikkik
Contributor
Forum|alt.badge.img+6
  • Author
  • Contributor
  • May 21, 2025

Thank you for your help everyone!

I got the results I needed, shout out to ​@alexbiz


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