Short answer:  Use mx.DateTime from egenix:

  http://www.egenix.com/files/python/eGenix-mx-Extensions.html#mxBASE

Here's sample code, once you've installed that:

$ python
>>> s1 = "Mon, 31 Dec 2001 15"
>>> import mx.DateTime
>>> d1 = mx.DateTime.DateFrom(s1)
>>> print d1
2001-12-31 00:00:00.00
>>> s2 = "Sat, 19 Jan 2002 21"
>>> d2 = mx.DateTime.DateFrom(s2)
>>> print (d2 > d1)
1

// mark
_______________________________________________
ActivePython mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/activepython

Reply via email to