I am trying to convert my datetime column to date.
Here is how my date value looks:
2023-06-25T00:00:00.000Z
and I want to convert it to
2023-06-25
This command;
df['date'].dt.strftime('%Y-%m-%d')
does not work.
The error message that I am getting states "Attribute Error: Can only use .dt accessor with datetime like values"
.
Also, when I run
df.info
it is stating that date is an object.
Any ideas on what I can do?