Question

4
Replies
5154
Views
Close popover
Mohammad Parwej Alam (MOHAMMAD_PARWEJ)
Ernst & Young LLP
Associate Technical Lead
Ernst & Young LLP
IN
MOHAMMAD_PARWEJ Member since 2015 19 posts
Ernst & Young LLP
Posted: April 9, 2018
Last activity: May 8, 2018
Closed
Solved

How to break/ split a string on the basis of specific length

Hi All,

I have a requirement. There is a property containing string value. I am using pxReplaceAllViaRegex function to replace/ remove some special chars/ regular expressions. But it seems when the length of the property value exceeds 2100, this functions fails. Currently this property is used in response DataTransform of Service REST rule. So how can I overcome this issue.

If I need to break/ split the property value for every 2000 charecters (i.e. on the basis of length), create a list (either value or page) and then loop it for substring. And for each splitted substring value use pxReplaceAllViaRegex and later concat it in a single property. How to achieve this within Data Transform. If not possible, please suggest the possible approach.

Thanks in advance!

Regards,

Parwej

Low-Code App Development Data Integration Java and Activities
Moderation Team has archived post