Hi team ,
Need help in creating regex format , I want to extract date from effective date
“Effective Date 2023-03-13”
I have created regex expressions like
(?<=Effective Date[\s*])([12]\d{3}-(0[1-9]|1[0-2]-(0[1-9][12]\d|3[01]))
But it’s not picking above date value , please let me know if am doing anything wrong ?
Regard
Krishna
Parvathy
(PS Parvathy)
3
Hi @Krishnakumar_Vasudevan
Use this regex in Find Matching Patterns activity
(?<=Effective Date\s)[\d\-]+
or use below syntax in Assign acxtivity:
strvar="Effective Date 2023-03-13"
Matches= System.Text.RegularExpressions.Regex.Match(strvar,"(?<=Effective Date\s)[\d\-]+").Value
Use this regex provided by you just made small changes to it:
(?<=Effective Date\s)([12]\d{3})-(0[1-9]|1[0-2])-(0[1-9]|[12][\d]|3[01])
Hope it helps!!
indra
(Indra)
4
Use this regex to get date
ppr
(Peter Preuss)
5
focussing on the date numbers part have a look here:
([12]\d{3})-(0[1-9]|1[0-2])-(0[1-9]|[12][\d]|3[01])

we guess there was just a pipe | missing

system
(system)
Closed
6
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.