title: Convert String to Date Object Ruby
body: <p>I'm trying to comvert a string in my logs to a date object. </p>
  
  <p>My string is <code>2018-09-18 11:42:50,286000201</code> which is the format <code>YYYY-MM-DD hh:mm:ss,nnnnnnnnn</code>
  I'm trying to convert in to an object using the time library in ruby. The function I am using is <code>Time.strptime('2018-09-18 11:42:50,286000201, '%Y-%m-%d %H:%M:%S,%9N')</code></p>
  
  <p>Ruby is giving me an invalid striptime format. Any help would be appreciated. Cheers. </p>