LauraMM
(Laura)
1
Input:
Vat-nr. 457674456
Department 4500 Pepsi Co
Employeeno. 6000 Avenue 5
Date 18-11-11 Newark
Accountant
John Doe Smith
Test Road 2
1234 Test Town
blabla
blabla
blabla
blablabla
Output
I want the first two lines in the second paragraph, here:
Accountant
John Doe Smith
strong text
Bonus: Can you explain the solution with the \r and \n
Hello @LauraMM
Is the word accountant constant?
Is there anything else that you can tell us about the pattern of text?
1 Like
LauraMM
(Laura)
3
Sorry. No it’s not a constant. It could be Director, Cleaning etc.
What I know is that it’s always the second paragraph that I want the first two lines from.
Hey @LauraMM
Have a look at this potential solution.
Pattern:
(?<=\n\n).*\n.*
However, you want the first match ONLY.
You will need to use an assign activity like this.
Stringvariable = REGEXRESULT(0).tostring
Update the above capital letters with the Result variable from the matches activity.
Hopefully this helps 
1 Like
Hello
For the bonus point - take a look at this link
Hopefully this helps also 
1 Like
LauraMM
(Laura)
6
1 Like
system
(system)
Closed
7
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.