Oct-14-2019, 10:34 AM
(This post was last modified: Oct-14-2019, 10:35 AM by LarsCordes.)
Hi all,
I'm trying to convert a dataframe column to a datetime format using
The column contains some 2,000 dates formatted YYYY-mm-dd. However, when I pass the relevant column, I receive the following error:
ValueError: to assemble mappings requires at least that [year, month, day] be specified: [day,month,year] is missing
Is there something different I need to do in order to ensure the df column is formatted correctly before passing to the to_datetime function?
Thanks for any help, this is really frustrating me!
I'm trying to convert a dataframe column to a datetime format using
pd.to_datetime(dataframe.column,infer_datetime_format=True)
The column contains some 2,000 dates formatted YYYY-mm-dd. However, when I pass the relevant column, I receive the following error:
ValueError: to assemble mappings requires at least that [year, month, day] be specified: [day,month,year] is missing
Is there something different I need to do in order to ensure the df column is formatted correctly before passing to the to_datetime function?
Thanks for any help, this is really frustrating me!