AnsweredAssumed Answered

RegEx Extract Duplicate

Question asked by deaconf19 on Feb 17, 2015
Latest reply on Feb 18, 2015 by deaconf19

I have email that is sent to a library. I then use the Query XML to write the email to a multi-line variable. My emails are always formatted the same way. For example I have a string like this.


The verification number: A123456


I'm using the following pattern (?:number:\s)([a-zA-Z0-9]+) with ignore case selected then I select Extract and the input text is the multi-line variable then store the results in a collection variable.


The problem is extract produces the following.


number: A123456;number: A123456;


Why am I getting duplicates? I have tried various patterns to pull EOL but it isn't working as expected so I reverted to the above which works.


Thanks for any help provided.




I failed to mention that the A123456 changes and is not the same that is why I'm trying to match the line that contains number: the move to EOL and extract that A123456 only