"Hi Everyone,
I need help with my problem.
Let say I have the string below:
Hi Team,
Please enroll the following devices for Genesis Care DEP ID 1393773.
SH51MM0L20F0N
SH51ML6AN0F0N
SH51MM0GR0F0N
SH51MM0GT0F0N
SH51MM0HV0F0N"
as you can see there are multiple instances that have SH followed by alphanumeric characters.
my goal is to extract all of it using regex.
is the possible?
hope someone can give me a hand on this
Regards
1 Like
Parvathy
(PS Parvathy)
July 11, 2024, 3:08am
2
Hi @alvin.c.apostol26
You can use the below regex ecpression:
^SH[A-Z0-9]+
Use the above regular expression in Find Matching Patterns activity. In options keep Compiled, IgnoreCase and MultiLine and stroe the output in a avriable say Matches.
Run a For Each Loop for Matches and print the values.
Hope it helps!!
rlgandu
(Rajyalakshmi Gandu)
July 11, 2024, 3:15am
3
@alvin.c.apostol26
SH\d+[A-Z]+\d+.*
Use Find Matching Pattern Activity to get the IEnumerable of matches and then use For each
Hi @Parvathy ,
For some reason it’s not highlighting in Regex Builder
I already selected the properties below:
Regards
alvin.c.apostol26:
Hi Everyone,
I need help with my problem.
Let say I have the string below:
Hi Team,
Please enroll the following devices for Genesis Care DEP ID 1393773.
SH51MM0L20F0N
SH51ML6AN0F0N
SH51MM0GR0F0N
SH51MM0GT0F0N
SH51MM0HV0F0N"
as you can see there are multiple instances that have SH followed by alphanumeric characters.
my goal is to extract all of it using regex.
is the possible?
hope someone can give me a hand on this
Regards
Thank you this worked for me!
Parvathy
(PS Parvathy)
July 11, 2024, 3:30am
7
Hi @alvin.c.apostol26
My expression will also work. Check the output once.
Output:
Regards
system
(system)
Closed
July 14, 2024, 3:30am
8
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.