<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:creativeCommons="http://backend.userland.com/creativeCommonsRssModule"
	>
<channel>
	<title>Comments on: datetime to string, easy; string to datetime&#8230; oh my, my!</title>
	<atom:link href="http://aralbalkan.com/1512/feed" rel="self" type="application/rss+xml" />
	<link>http://aralbalkan.com/1512</link>
	<description>Passionate geekisms.</description>
	<lastBuildDate>Thu, 18 Mar 2010 08:13:38 -0700</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Shubhadeep</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-256192</link>
		<dc:creator>Shubhadeep</dc:creator>
		<pubDate>Sat, 13 Jun 2009 07:03:37 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-256192</guid>
		<description>Thanks Man!
You saved me a lot of time

Thanks again</description>
		<content:encoded><![CDATA[<p>Thanks Man!<br />
You saved me a lot of time</p>
<p>Thanks again</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-213501</link>
		<dc:creator>Dave</dc:creator>
		<pubDate>Thu, 05 Feb 2009 05:37:55 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-213501</guid>
		<description>sorry, tried 3 times to post with indenting -- as we all know, in python, whitespace counts!

If you can&#039;t determine the proper indentation and you actually want the code, let me know by email: 

davydm _AT_ gmail _DOT_ com

Sorry for the comment spam!</description>
		<content:encoded><![CDATA[<p>sorry, tried 3 times to post with indenting &#8212; as we all know, in python, whitespace counts!</p>
<p>If you can&#8217;t determine the proper indentation and you actually want the code, let me know by email: </p>
<p>davydm _AT_ gmail _DOT_ com</p>
<p>Sorry for the comment spam!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-213498</link>
		<dc:creator>Dave</dc:creator>
		<pubDate>Thu, 05 Feb 2009 05:35:28 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-213498</guid>
		<description>&lt;code&gt;
import datetime
import sys
import os

# much fudgery
def utctime(dt):
  return (((dt.toordinal()-719163)*24+dt.hour)*60+dt.minute)*60+dt.second

def try_formats():
  ret = []
  ret.append(&quot;%Y-%m-%d&quot;)
  ret.append(&quot;%Y/%m/%d&quot;)
  ret.append(&quot;%d/%m/%Y&quot;)
  ret.append(&quot;%d-%m-%Y&quot;)
  ret.append(&quot;%d/%m/%y&quot;)
  ret.append(&quot;%d-%m-%y&quot;)
  ret.append(&quot;%Y-%m-%d %H:%M:%S&quot;)
  ret.append(&quot;%d-%m-%Y %H:%M:%S&quot;)
  ret.append(&quot;%Y/%m/%d %H:%M:%S&quot;)
  ret.append(&quot;%d/%m/%Y %H:%M:%S&quot;)
  ret.append(&quot;%d-%m-%y %H:%M:%S&quot;)
  ret.append(&quot;%y/%m/%d %H:%M:%S&quot;)
  ret.append(&quot;%d/%m/%y %H:%M:%S&quot;)
  ret.append(&quot;%Y-%m-%d %H:%M&quot;)
  ret.append(&quot;%d-%m-%Y %H:%M&quot;)
  ret.append(&quot;%Y/%m/%d %H:%M&quot;)
  ret.append(&quot;%d/%m/%Y %H:%M&quot;)
  ret.append(&quot;%d-%m-%y %H:%M&quot;)
  ret.append(&quot;%y/%m/%d %H:%M&quot;)
  ret.append(&quot;%d/%m/%y %H:%M&quot;)
  return ret


def show_date(s):
  FORMAT=&quot;%Y-%m-%d %H:%M:%S&quot;
  try:
    secs = int(s)
    d = datetime.datetime.fromtimestamp(secs)
    print(str(secs) + &quot; :: &quot; + d.strftime(FORMAT))
    return
  except:
    pass

  for f in try_formats():
    try:
      d = datetime.datetime.strptime(s, f)
      secs = utctime(d)
      print(str(secs) + &quot; :: &quot; + d.strftime(FORMAT))
      return
    except:
      pass

  print(&quot;Unable to grok datetime / int string &#039;&quot; + s + &quot;&#039;&quot;)

def usage():
  print(os.path.basename(sys.argv[0]) + &quot;  ...&quot;)
  print(&quot;  attempts to grok the date from the string you provided and&quot;)
  print(&quot;  prints out a timestamp and date string for all arguments&quot;)

if __name__ == &quot;__main__&quot;:
  if len(sys.argv) == 1:
    usage()
  else:
    for arg in sys.argv[1:]:
      if (arg == &quot;--help&quot;) or (arg == &quot;-h&quot;):
        usage()
      else:
        show_date(arg)
&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p><code><br />
import datetime<br />
import sys<br />
import os</p>
<p># much fudgery<br />
def utctime(dt):<br />
  return (((dt.toordinal()-719163)*24+dt.hour)*60+dt.minute)*60+dt.second</p>
<p>def try_formats():<br />
  ret = []<br />
  ret.append("%Y-%m-%d")<br />
  ret.append("%Y/%m/%d")<br />
  ret.append("%d/%m/%Y")<br />
  ret.append("%d-%m-%Y")<br />
  ret.append("%d/%m/%y")<br />
  ret.append("%d-%m-%y")<br />
  ret.append("%Y-%m-%d %H:%M:%S")<br />
  ret.append("%d-%m-%Y %H:%M:%S")<br />
  ret.append("%Y/%m/%d %H:%M:%S")<br />
  ret.append("%d/%m/%Y %H:%M:%S")<br />
  ret.append("%d-%m-%y %H:%M:%S")<br />
  ret.append("%y/%m/%d %H:%M:%S")<br />
  ret.append("%d/%m/%y %H:%M:%S")<br />
  ret.append("%Y-%m-%d %H:%M")<br />
  ret.append("%d-%m-%Y %H:%M")<br />
  ret.append("%Y/%m/%d %H:%M")<br />
  ret.append("%d/%m/%Y %H:%M")<br />
  ret.append("%d-%m-%y %H:%M")<br />
  ret.append("%y/%m/%d %H:%M")<br />
  ret.append("%d/%m/%y %H:%M")<br />
  return ret</p>
<p>def show_date(s):<br />
  FORMAT="%Y-%m-%d %H:%M:%S"<br />
  try:<br />
    secs = int(s)<br />
    d = datetime.datetime.fromtimestamp(secs)<br />
    print(str(secs) + " :: " + d.strftime(FORMAT))<br />
    return<br />
  except:<br />
    pass</p>
<p>  for f in try_formats():<br />
    try:<br />
      d = datetime.datetime.strptime(s, f)<br />
      secs = utctime(d)<br />
      print(str(secs) + " :: " + d.strftime(FORMAT))<br />
      return<br />
    except:<br />
      pass</p>
<p>  print("Unable to grok datetime / int string '" + s + "'")</p>
<p>def usage():<br />
  print(os.path.basename(sys.argv[0]) + "  ...")<br />
  print("  attempts to grok the date from the string you provided and")<br />
  print("  prints out a timestamp and date string for all arguments")</p>
<p>if __name__ == "__main__":<br />
  if len(sys.argv) == 1:<br />
    usage()<br />
  else:<br />
    for arg in sys.argv[1:]:<br />
      if (arg == "--help") or (arg == "-h"):<br />
        usage()<br />
      else:<br />
        show_date(arg)<br />
</code></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-213497</link>
		<dc:creator>Dave</dc:creator>
		<pubDate>Thu, 05 Feb 2009 05:34:55 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-213497</guid>
		<description>
import datetime
import sys
import os

# much fudgery
def utctime(dt):
  return (((dt.toordinal()-719163)*24+dt.hour)*60+dt.minute)*60+dt.second

def try_formats():
  ret = []
  ret.append(&quot;%Y-%m-%d&quot;)
  ret.append(&quot;%Y/%m/%d&quot;)
  ret.append(&quot;%d/%m/%Y&quot;)
  ret.append(&quot;%d-%m-%Y&quot;)
  ret.append(&quot;%d/%m/%y&quot;)
  ret.append(&quot;%d-%m-%y&quot;)
  ret.append(&quot;%Y-%m-%d %H:%M:%S&quot;)
  ret.append(&quot;%d-%m-%Y %H:%M:%S&quot;)
  ret.append(&quot;%Y/%m/%d %H:%M:%S&quot;)
  ret.append(&quot;%d/%m/%Y %H:%M:%S&quot;)
  ret.append(&quot;%d-%m-%y %H:%M:%S&quot;)
  ret.append(&quot;%y/%m/%d %H:%M:%S&quot;)
  ret.append(&quot;%d/%m/%y %H:%M:%S&quot;)
  ret.append(&quot;%Y-%m-%d %H:%M&quot;)
  ret.append(&quot;%d-%m-%Y %H:%M&quot;)
  ret.append(&quot;%Y/%m/%d %H:%M&quot;)
  ret.append(&quot;%d/%m/%Y %H:%M&quot;)
  ret.append(&quot;%d-%m-%y %H:%M&quot;)
  ret.append(&quot;%y/%m/%d %H:%M&quot;)
  ret.append(&quot;%d/%m/%y %H:%M&quot;)
  return ret


def show_date(s):
  FORMAT=&quot;%Y-%m-%d %H:%M:%S&quot;
  try:
    secs = int(s)
    d = datetime.datetime.fromtimestamp(secs)
    print(str(secs) + &quot; :: &quot; + d.strftime(FORMAT))
    return
  except:
    pass

  for f in try_formats():
    try:
      d = datetime.datetime.strptime(s, f)
      secs = utctime(d)
      print(str(secs) + &quot; :: &quot; + d.strftime(FORMAT))
      return
    except:
      pass

  print(&quot;Unable to grok datetime / int string &#039;&quot; + s + &quot;&#039;&quot;)

def usage():
  print(os.path.basename(sys.argv[0]) + &quot;  ...&quot;)
  print(&quot;  attempts to grok the date from the string you provided and&quot;)
  print(&quot;  prints out a timestamp and date string for all arguments&quot;)

if __name__ == &quot;__main__&quot;:
  if len(sys.argv) == 1:
    usage()
  else:
    for arg in sys.argv[1:]:
      if (arg == &quot;--help&quot;) or (arg == &quot;-h&quot;):
        usage()
      else:
        show_date(arg)
</description>
		<content:encoded><![CDATA[<p>import datetime<br />
import sys<br />
import os</p>
<p># much fudgery<br />
def utctime(dt):<br />
  return (((dt.toordinal()-719163)*24+dt.hour)*60+dt.minute)*60+dt.second</p>
<p>def try_formats():<br />
  ret = []<br />
  ret.append(&#8221;%Y-%m-%d&#8221;)<br />
  ret.append(&#8221;%Y/%m/%d&#8221;)<br />
  ret.append(&#8221;%d/%m/%Y&#8221;)<br />
  ret.append(&#8221;%d-%m-%Y&#8221;)<br />
  ret.append(&#8221;%d/%m/%y&#8221;)<br />
  ret.append(&#8221;%d-%m-%y&#8221;)<br />
  ret.append(&#8221;%Y-%m-%d %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%d-%m-%Y %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%Y/%m/%d %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%d/%m/%Y %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%d-%m-%y %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%y/%m/%d %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%d/%m/%y %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%Y-%m-%d %H:%M&#8221;)<br />
  ret.append(&#8221;%d-%m-%Y %H:%M&#8221;)<br />
  ret.append(&#8221;%Y/%m/%d %H:%M&#8221;)<br />
  ret.append(&#8221;%d/%m/%Y %H:%M&#8221;)<br />
  ret.append(&#8221;%d-%m-%y %H:%M&#8221;)<br />
  ret.append(&#8221;%y/%m/%d %H:%M&#8221;)<br />
  ret.append(&#8221;%d/%m/%y %H:%M&#8221;)<br />
  return ret</p>
<p>def show_date(s):<br />
  FORMAT=&#8221;%Y-%m-%d %H:%M:%S&#8221;<br />
  try:<br />
    secs = int(s)<br />
    d = datetime.datetime.fromtimestamp(secs)<br />
    print(str(secs) + &#8221; :: &#8221; + d.strftime(FORMAT))<br />
    return<br />
  except:<br />
    pass</p>
<p>  for f in try_formats():<br />
    try:<br />
      d = datetime.datetime.strptime(s, f)<br />
      secs = utctime(d)<br />
      print(str(secs) + &#8221; :: &#8221; + d.strftime(FORMAT))<br />
      return<br />
    except:<br />
      pass</p>
<p>  print(&#8221;Unable to grok datetime / int string &#8216;&#8221; + s + &#8220;&#8216;&#8221;)</p>
<p>def usage():<br />
  print(os.path.basename(sys.argv[0]) + &#8221;  &#8230;&#8221;)<br />
  print(&#8221;  attempts to grok the date from the string you provided and&#8221;)<br />
  print(&#8221;  prints out a timestamp and date string for all arguments&#8221;)</p>
<p>if __name__ == &#8220;__main__&#8221;:<br />
  if len(sys.argv) == 1:<br />
    usage()<br />
  else:<br />
    for arg in sys.argv[1:]:<br />
      if (arg == &#8220;&#8211;help&#8221;) or (arg == &#8220;-h&#8221;):<br />
        usage()<br />
      else:<br />
        show_date(arg)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-213496</link>
		<dc:creator>Dave</dc:creator>
		<pubDate>Thu, 05 Feb 2009 05:34:20 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-213496</guid>
		<description>There&#039;s a cheaper (as in &quot;cheap-n-nasty&quot;), more easily extensible method

The following code converts a timestamp or date string to a date object and prints it out (I needed to be able to do this for an arb reason):


#begin code
import datetime
import sys
import os

# much fudgery
def utctime(dt):
  return (((dt.toordinal()-719163)*24+dt.hour)*60+dt.minute)*60+dt.second

def try_formats():
  ret = []
  ret.append(&quot;%Y-%m-%d&quot;)
  ret.append(&quot;%Y/%m/%d&quot;)
  ret.append(&quot;%d/%m/%Y&quot;)
  ret.append(&quot;%d-%m-%Y&quot;)
  ret.append(&quot;%d/%m/%y&quot;)
  ret.append(&quot;%d-%m-%y&quot;)
  ret.append(&quot;%Y-%m-%d %H:%M:%S&quot;)
  ret.append(&quot;%d-%m-%Y %H:%M:%S&quot;)
  ret.append(&quot;%Y/%m/%d %H:%M:%S&quot;)
  ret.append(&quot;%d/%m/%Y %H:%M:%S&quot;)
  ret.append(&quot;%d-%m-%y %H:%M:%S&quot;)
  ret.append(&quot;%y/%m/%d %H:%M:%S&quot;)
  ret.append(&quot;%d/%m/%y %H:%M:%S&quot;)
  ret.append(&quot;%Y-%m-%d %H:%M&quot;)
  ret.append(&quot;%d-%m-%Y %H:%M&quot;)
  ret.append(&quot;%Y/%m/%d %H:%M&quot;)
  ret.append(&quot;%d/%m/%Y %H:%M&quot;)
  ret.append(&quot;%d-%m-%y %H:%M&quot;)
  ret.append(&quot;%y/%m/%d %H:%M&quot;)
  ret.append(&quot;%d/%m/%y %H:%M&quot;)
  return ret


def show_date(s):
  FORMAT=&quot;%Y-%m-%d %H:%M:%S&quot;
  try:
    secs = int(s)
    d = datetime.datetime.fromtimestamp(secs)
    print(str(secs) + &quot; :: &quot; + d.strftime(FORMAT))
    return
  except:
    pass

  for f in try_formats():
    try:
      d = datetime.datetime.strptime(s, f)
      secs = utctime(d)
      print(str(secs) + &quot; :: &quot; + d.strftime(FORMAT))
      return
    except:
      pass

  print(&quot;Unable to grok datetime / int string &#039;&quot; + s + &quot;&#039;&quot;)

def usage():
  print(os.path.basename(sys.argv[0]) + &quot;  ...&quot;)
  print(&quot;  attempts to grok the date from the string you provided and&quot;)
  print(&quot;  prints out a timestamp and date string for all arguments&quot;)

if __name__ == &quot;__main__&quot;:
  if len(sys.argv) == 1:
    usage()
  else:
    for arg in sys.argv[1:]:
      if (arg == &quot;--help&quot;) or (arg == &quot;-h&quot;):
        usage()
      else:
        show_date(arg)

#end code

Hope it helps someone.</description>
		<content:encoded><![CDATA[<p>There&#8217;s a cheaper (as in &#8220;cheap-n-nasty&#8221;), more easily extensible method</p>
<p>The following code converts a timestamp or date string to a date object and prints it out (I needed to be able to do this for an arb reason):</p>
<p>#begin code<br />
import datetime<br />
import sys<br />
import os</p>
<p># much fudgery<br />
def utctime(dt):<br />
  return (((dt.toordinal()-719163)*24+dt.hour)*60+dt.minute)*60+dt.second</p>
<p>def try_formats():<br />
  ret = []<br />
  ret.append(&#8221;%Y-%m-%d&#8221;)<br />
  ret.append(&#8221;%Y/%m/%d&#8221;)<br />
  ret.append(&#8221;%d/%m/%Y&#8221;)<br />
  ret.append(&#8221;%d-%m-%Y&#8221;)<br />
  ret.append(&#8221;%d/%m/%y&#8221;)<br />
  ret.append(&#8221;%d-%m-%y&#8221;)<br />
  ret.append(&#8221;%Y-%m-%d %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%d-%m-%Y %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%Y/%m/%d %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%d/%m/%Y %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%d-%m-%y %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%y/%m/%d %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%d/%m/%y %H:%M:%S&#8221;)<br />
  ret.append(&#8221;%Y-%m-%d %H:%M&#8221;)<br />
  ret.append(&#8221;%d-%m-%Y %H:%M&#8221;)<br />
  ret.append(&#8221;%Y/%m/%d %H:%M&#8221;)<br />
  ret.append(&#8221;%d/%m/%Y %H:%M&#8221;)<br />
  ret.append(&#8221;%d-%m-%y %H:%M&#8221;)<br />
  ret.append(&#8221;%y/%m/%d %H:%M&#8221;)<br />
  ret.append(&#8221;%d/%m/%y %H:%M&#8221;)<br />
  return ret</p>
<p>def show_date(s):<br />
  FORMAT=&#8221;%Y-%m-%d %H:%M:%S&#8221;<br />
  try:<br />
    secs = int(s)<br />
    d = datetime.datetime.fromtimestamp(secs)<br />
    print(str(secs) + &#8221; :: &#8221; + d.strftime(FORMAT))<br />
    return<br />
  except:<br />
    pass</p>
<p>  for f in try_formats():<br />
    try:<br />
      d = datetime.datetime.strptime(s, f)<br />
      secs = utctime(d)<br />
      print(str(secs) + &#8221; :: &#8221; + d.strftime(FORMAT))<br />
      return<br />
    except:<br />
      pass</p>
<p>  print(&#8221;Unable to grok datetime / int string &#8216;&#8221; + s + &#8220;&#8216;&#8221;)</p>
<p>def usage():<br />
  print(os.path.basename(sys.argv[0]) + &#8221;  &#8230;&#8221;)<br />
  print(&#8221;  attempts to grok the date from the string you provided and&#8221;)<br />
  print(&#8221;  prints out a timestamp and date string for all arguments&#8221;)</p>
<p>if __name__ == &#8220;__main__&#8221;:<br />
  if len(sys.argv) == 1:<br />
    usage()<br />
  else:<br />
    for arg in sys.argv[1:]:<br />
      if (arg == &#8220;&#8211;help&#8221;) or (arg == &#8220;-h&#8221;):<br />
        usage()<br />
      else:<br />
        show_date(arg)</p>
<p>#end code</p>
<p>Hope it helps someone.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: OzgurBatu</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-190583</link>
		<dc:creator>OzgurBatu</dc:creator>
		<pubDate>Wed, 15 Oct 2008 19:54:57 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-190583</guid>
		<description>it realy works. Thank you...</description>
		<content:encoded><![CDATA[<p>it realy works. Thank you&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: chat</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-190202</link>
		<dc:creator>chat</dc:creator>
		<pubDate>Sun, 12 Oct 2008 17:08:18 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-190202</guid>
		<description>thank you admin</description>
		<content:encoded><![CDATA[<p>thank you admin</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: htmlmekani</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-190200</link>
		<dc:creator>htmlmekani</dc:creator>
		<pubDate>Sun, 12 Oct 2008 16:42:20 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-190200</guid>
		<description>thanks aral. l want to ask a question. oyur page rank 6 now. why. :(</description>
		<content:encoded><![CDATA[<p>thanks aral. l want to ask a question. oyur page rank 6 now. why. :(</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: widged</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-190014</link>
		<dc:creator>widged</dc:creator>
		<pubDate>Fri, 10 Oct 2008 21:09:12 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-190014</guid>
		<description>Could DateUtil be of help (&lt;a href=&quot;http://code.google.com/p/as3corelib/&quot; rel=&quot;nofollow&quot;&gt;as3 corelib&lt;/a&gt;, com.adobe.utils.DateUtil). For string to date conversion, they zhave parseRFC822, parseW3CDTF

&lt;a href=&quot;http://www.adobe.com/cfusion/communityengine/index.cfm?event=showdetails&amp;postId=3261&amp;productId=2&amp;loc=en_US&quot; rel=&quot;nofollow&quot;&gt;A quick Actionscript 3 workaround for MS SQL Server default date-time parsing&lt;/a&gt;

When using Flex, the &lt;a href=&quot;http://livedocs.adobe.com/flex/3/langref/mx/controls/DateField.html&quot; rel=&quot;nofollow&quot;&gt;DateField&lt;/a&gt; control has a stringToDate method. 

var dob:Date = DateField.stringToDate(&quot;06/30/2005&quot;, &quot;MM/DD/YYYY&quot;);</description>
		<content:encoded><![CDATA[<p>Could DateUtil be of help (<a href="http://code.google.com/p/as3corelib/" rel="nofollow">as3 corelib</a>, com.adobe.utils.DateUtil). For string to date conversion, they zhave parseRFC822, parseW3CDTF</p>
<p><a href="http://www.adobe.com/cfusion/communityengine/index.cfm?event=showdetails&amp;postId=3261&amp;productId=2&amp;loc=en_US" rel="nofollow">A quick Actionscript 3 workaround for MS SQL Server default date-time parsing</a></p>
<p>When using Flex, the <a href="http://livedocs.adobe.com/flex/3/langref/mx/controls/DateField.html" rel="nofollow">DateField</a> control has a stringToDate method. </p>
<p>var dob:Date = DateField.stringToDate(&#8221;06/30/2005&#8243;, &#8220;MM/DD/YYYY&#8221;);</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bill</title>
		<link>http://aralbalkan.com/1512/comment-page-1#comment-189993</link>
		<dc:creator>Bill</dc:creator>
		<pubDate>Fri, 10 Oct 2008 18:15:34 +0000</pubDate>
		<guid isPermaLink="false">http://aralbalkan.com/1512#comment-189993</guid>
		<description>What about datetime.datetime.strptime(time_string, &#039;%Y-%m-%d %H:%M:%S&#039;)?
My date strings from client ignore sub-second but the format could be adjusted.</description>
		<content:encoded><![CDATA[<p>What about datetime.datetime.strptime(time_string, &#8216;%Y-%m-%d %H:%M:%S&#8217;)?<br />
My date strings from client ignore sub-second but the format could be adjusted.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
