Should be simple enough. I have a datetime object in python, I need it to be of the form
20131002
Is there a way to format this without having to resort to breaking the date into it's components and putting them together in a string manually?
This is super easy in the Python datetime library:
from datetime import datetime
test = datetime.now() # This is just some test datetime object
test.strftime('%Y%m%d') # This is the format statement
However, a quick Google search shows me that you would find similar answers by searching for "python datetime format".
datetime.strftime?