Matching the same expression

Hi everyone

I have a pattern which comes in excel like

Now their might be empty cell or these 3 types of pattern. these all needs to be accepted for any other pattern or any count less or something it must say it is invalid.
and these 3 no.'s written have a very small difference… Please anyone try this . Urgent…

1 Like

Hello Krishna,

so you want to iterate through each row and validate this pattern??

hi @Pradeep_Shiv


1 Like

Hi @Krishna_Sanghi

Others with good regex knowledge can have a better elegant solution, but here is the basic string check.

I see that the string pattern can have 24 character and 6 underscores (or 7 parts when split on _)

IF: row("PatternColumn").ToString.Split("_"c).Count = 7 AND row("PatternColumn").ToString.Length = 24
Then : Do something
Else : Ignore or Invalid

Here is the suggestion: PatternMatch.xaml (7.6 KB)

Hope this helps!


Hello @Krishna_Sanghi,

Sorry for the delay!

  • Use Read Range, and get output like outDt

  • For each row, Pass outDt

  • Use IF Activity like Not String.IsNullOrEmpty(row(“yourColumnName”).ToString)

Then: IsMatches Activity and pass input as row(“yourColumnName”).ToString and Pattern as [A-Za-z]{1}_\d{6}_\d{3}_[A-Za-z]{2}_\d{4}_[A-Za-z]{1}_[A-Za-z]{1}

Else: Row value is empty

if the pattern matches you’ll get return output as True if not False based on the output you can develop the process.

you can test the expression here Regex


1 Like

Hi @Pradeep_Shiv

Thanks for the solution, I was not able to develop this regexp. It works

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.