Skip to main content
Solved

Trim first characters of manz attributes

  • August 13, 2014
  • 2 replies
  • 49 views

Hi,

 

 

I have many attributes with len 13. Need to remove first 5 characters of each of them (these 5 can be different).

E.g. att1=1001478577259

 

        att2=1247833654578 and so on.

 

need to get : att1=78577259

 

                       att2=33654578

How to do this without putting multiple SubstringExtractors?

Best answer by takashi

Hi,

 

 

You can use the StringReplacer with regular expression. For example,

 

Attributes: attr1, attr2, ...

 

Text to Match: ^.{5}(.+)$

 

Replacement Text: \\1

 

Use Regular Expressions: Yes

 

 

Takashi
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

takashi
Celebrity
  • Best Answer
  • August 13, 2014
Hi,

 

 

You can use the StringReplacer with regular expression. For example,

 

Attributes: attr1, attr2, ...

 

Text to Match: ^.{5}(.+)$

 

Replacement Text: \\1

 

Use Regular Expressions: Yes

 

 

Takashi

  • Author
  • August 13, 2014
Takashi,

 

 

Great thanks.

 

 

Aleksandar