Skip to main content
Solved

Fixing street names all in lower case

  • April 24, 2024
  • 2 replies
  • 67 views

scarter
Contributor
Forum|alt.badge.img+10

Hello Forum,

 

I have an externally supplied dataset which includes a street name. Some of the street name entries are all in lower case (e.g.: royal road) where it should be Royal Road. However some entries are fine.

This is part of a larger regular data process, so I’d like to build in a process that fixes street names to proper upper/lower case (e.g.: royal road would become Royal Road).

 

Is this possible in FME Form?

 

 

Thanks,

Stuart

 

Best answer by nielsgerrits

One way to do this is to use the StringCaseChanger set to Full Title Case.

Or use the function

@FullTitleCase(@Value(Street_name))

in an AttributeCreator.

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

nielsgerrits
VIP
Forum|alt.badge.img+62
  • Best Answer
  • April 24, 2024

One way to do this is to use the StringCaseChanger set to Full Title Case.

Or use the function

@FullTitleCase(@Value(Street_name))

in an AttributeCreator.


patrick.gress
Contributor
Forum|alt.badge.img+3

You could use a python caller, too:

 

    def input(self, feature: fmeobjects.FMEFeature):
street = feature.getAttribute('street')
street_fix = ' '.join(map(str.capitalize, street.split(' ')))
feature.setAttribute('street', street_fix)
self.pyoutput(feature)