I'm trying to learn RegEx and tried to solve the below scenario:
Assume the the below string is a cell in a data input with thousands of rows:
"He who sleeps on the floor will not fall off the bed.Robert Gronock16-APR-2005This is a valid record."
I wrote the Regex ".+\s*(\d+-.+-\d+|[[:alpha:]]{3}\s*\d+,*\s\d+)"
to extract the date only from the string but what I get is 6-APR-2005
missing the 1 at the beginning.
I don't want to use {2} as some rows has single digit like 8-Apr-2005 and it would return Null.
What I am doing wrong in the RegEx?