Re: converting string to a date format

2009-12-22 Thread M.-A. Lemburg
tekion wrote: > All, > I know there is a datetime module for converting and manipulate date > format. I have this string date format: 24/Nov/2009:10:39:03 -0500 > and would like to convert it to a date format of "2009-11-24 > 10:39:03". At the moment I am reading datetime module trying to find >

Re: converting string to a date format

2009-12-21 Thread Ben Finney
tekion writes: > Ben, > I do not have python 2.6 install, my version of Python is 2.4. Ouch :-( Upgrade as soon as possible, 2.4 is no longer receiving bug fixes http://www.python.org/download/releases/2.4.6/>. > So I guess I am stuck on parsing the string "24/Nov/2009:12:00:00 > -0500" using r

Re: converting string to a date format

2009-12-21 Thread tekion
On Dec 21, 3:05 pm, MRAB wrote: > tekionwrote: > > Ben, > > I do not have python 2.6 install, my version of Python is 2.4. > > Because of my version of Python I believe I have to perform what you > > have suggested: > > > This should, ideally, consist of two separate operations: > > >   * parse th

Re: converting string to a date format

2009-12-21 Thread MRAB
tekion wrote: Ben, I do not have python 2.6 install, my version of Python is 2.4. Because of my version of Python I believe I have to perform what you have suggested: This should, ideally, consist of two separate operations: * parse the string, using a specific format, to create a ‘datetime’

Re: converting string to a date format

2009-12-21 Thread tekion
Ben, I do not have python 2.6 install, my version of Python is 2.4. Because of my version of Python I believe I have to perform what you have suggested: This should, ideally, consist of two separate operations: * parse the string, using a specific format, to create a ‘datetime’ object *

Re: converting string to a date format

2009-12-20 Thread Ben Finney
tekion writes: > I have this string date format: 24/Nov/2009:10:39:03 -0500 and would > like to convert it to a date format of "2009-11-24 10:39:03". This should, ideally, consist of two separate operations: * parse the string, using a specific format, to create a ‘datetime’ object * c

Re: converting string to a date format

2009-12-20 Thread MRAB
tekion wrote: All, I know there is a datetime module for converting and manipulate date format. I have this string date format: 24/Nov/2009:10:39:03 -0500 and would like to convert it to a date format of "2009-11-24 10:39:03". At the moment I am reading datetime module trying to find out if I

converting string to a date format

2009-12-20 Thread tekion
All, I know there is a datetime module for converting and manipulate date format. I have this string date format: 24/Nov/2009:10:39:03 -0500 and would like to convert it to a date format of "2009-11-24 10:39:03". At the moment I am reading datetime module trying to find out if I could do it with