We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Regex

sswift13
7 - Meteor

I am searching a column to find data that matches "P****" where those four addition characters could be numbers or letters. Currently, I have 

ELSEIF regex_match([Prefix], 'P\d{4}.*') then

However, I believe this only searches for numbers.

 

How can I search for both letters and numbers? The word is usually "[letter][letter][letter][number][number]".

2 REPLIES 2
mpennington
11 - Bolide

\w will match any word character, so both numbers and letters:

 

RegEx.jpg

apathetichell
20 - Arcturus

.{4} would be any four characters and [0-9A-Za-z]{4} would be any combination of exactly 4 numbers or letters.

Labels
Top Solution Authors