RE: DatePart From String

2007-07-03 Thread Robert Rawlins - Think Blue
AIL PROTECTED] On Behalf Of Dave Sent: 03 July 2007 10:46 To: python-list@python.org Subject: Re: DatePart From String Robert Rawlins - Think Blue thinkbluemedia.co.uk> writes: > I’ve tried using the time.strptime() function without much success so > thought I’d come and ask your advi

Re: DatePart From String

2007-07-03 Thread Dave
Robert Rawlins - Think Blue thinkbluemedia.co.uk> writes: > I’ve tried using the time.strptime() function without much success so > thought I’d come and ask your advice. > How exactly does it not work?? This works for me: from time import mktime, strptime from datetime import datetime dateti

DatePart From String

2007-07-03 Thread Robert Rawlins - Think Blue
Hello Guys, I have a date/time as a string which looks like this: 2007-02-01 00:00:00 I'm trying to get my hands on the different date parts of that string in the following formats: Time Only: 00:00:00 Day As Number: 01 Month As Number: 02 Day As Word: Monday I've tried using the