Python Forum
df string manipulation before / after / when single digit pad zero
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
df string manipulation before / after / when single digit pad zero
#4
Hi snippsat,
Many thanks for your reply.
Is there a way to try parsing it, if it doesnt parse, then it doesnt.
I have dates that contain strings or even months as strings in different languages.
It would be good if no exception is thrown, when the parsing fails.

    d=datetime(1984, 1, 'May', 0, 0)
    d.strftime(f'{d:%d/%m/%Y}')
    print(d)
Reply


Messages In This Thread
RE: df string manipulation before / after / when single digit pad zero - by metalray - Oct-16-2018, 01:32 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020