cancel
Showing results for 
Search instead for 
Did you mean: 

Split text by length

DilipK
Level 3
Hi Team,

I am trying to split the text based upon some certain count(lets assume as 5) 

Input parameter:

The input [test]: 36444      36481      3650136588      36601 (Please note there are some spaces in between)

Maximum Line Length: 5

outpu parametert:
Split Lines : collection


Outcome is :Empty spaces are not considered. It is considering only the values in it.

1)36444
2)36481
3)36501
4)36588
5)
36601


Expectation is : Empty spaces should also be considered in output collection
1)36444
2)
3)36481
4)
5)36501
6)36588
7)
😎
36601

Do we have any way to overcome this?

Thank you!

Regards,
Dilip K

1 BEST ANSWER

Best Answers

Hi Dilip - sorry for the late response. You can try several calc states where you do regular expressions to obtain right(text, length) several times.You will need some interim stages where you trim the text and keep going until you finish with the input data. Or, you can also use a loop (or more) to cycle through the source data. See if this works and good luck!

------------------------------
Alexander Marlowe
Blue Prism
Blue Prism
------------------------------

View answer in original post

1 REPLY 1

Hi Dilip - sorry for the late response. You can try several calc states where you do regular expressions to obtain right(text, length) several times.You will need some interim stages where you trim the text and keep going until you finish with the input data. Or, you can also use a loop (or more) to cycle through the source data. See if this works and good luck!

------------------------------
Alexander Marlowe
Blue Prism
Blue Prism
------------------------------