I have a data frame like this:
Date
9/02/2019
12/08/2019
8/06/2019
I want to add a 0
in infront of dates that are in single digit. I want it to be like this:
Date
09/02/2019
12/08/2019
08/06/2019
I am using this RegEx and the string manipulation. The string manipulation by itself works, but when I try to work it out with the RegEx, it doesn't yield anything.
if row['Date'] == r'[\d]{1}/[\d]{1,2}/[\d]{4}':
row['blah'] = '0' + row['Date']
print(row['blah'])
else:
pass