community
cancel
Showing results for 
Search instead for 
Did you mean: 

Alteryx designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
Community v19.6

Looks aren't everything... But the latest Community refresh looks darn good!

Learn More

Regex Match

Meteoroid

Hi,

 

I am trying to match a string to the following Regex formula and i am not coming out with any true. I would like to pull Rev # or Rev#. Below is an example of the string and regex formula i am using. Please let me know, thanks.

 

Formula - Rev\s\d

 

String - DWG-10-0383 Rev 1 Button, Singulation, Subassembly, G2-U.PDF

Bolide

Hi @Austin_Riggs 

 

Assuming the # is referring to a number, try:

REGEX_Match([Field1], "(reg)[ ]{0,1}\d")

 

Which would give you this:

Regex2.PNG

 

 

 

Hope that helps

Andy

Aurora

Hi @Austin_Riggs 

 

Since you mention that you want to pull the revision number as well, the attached workflows does that.  It uses a Regex Parse tool in Parse mode with the following regex

(rev)[ ]{0,}(\d+)

 

to pull out the Revision marker string "Rev" as well as the number itself.

 

Results.png

 

 

Dan

 

 

 

Labels