How do you go about the string '2014-03-16 18:28:11' back to datetime.datetime. I was wondering if there an easier way than the below
>>> datetime.datetime(2014, 3, 16, 18, 28, 11)
>>> str(datetime.datetime(2014, 3, 16, 18, 28, 11))
'2014-03-16 18:28:11'
>>> complete = str(datetime.datetime(2014, 3, 16, 18, 28, 11))
>>> date, time = complete.split(" ")
>>> [int(x) for x in date.split("-")]
[2014, 3, 16]
>>> [int(x) for x in time.split(":")]
[18, 28, 11]
Then use each variable as inputs to datetime.datetime