[BangPypers] date/time difference between two dates

LOhit lohit.b at gmail.com
Thu Feb 19 11:59:01 CET 2009

Hello All,

I am parsing a log file to extract data for the last one week from the
current date. The log file does not record the year, only month, day of the
month and time.

My question is, the date is in "Month day-of-the-month time" format in the
log file (ex. "Nov 22 15:15:42") and the current date I get from "datetime"
module is in ISO format. How do I convert the date in log file to ISO
format(or any other format) and then compare with the current date/time.

I am sure this will sound like a simple problem to you experts, but, I am
not a programmer. I am a python enthusiast trying to automate few of my


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/bangpypers/attachments/20090219/e4ddd31c/attachment.htm>

More information about the BangPypers mailing list