From: snex Date: 2009-02-28T06:49:03+09:00 Subject: Re: little prob with Date.strptime On Feb 27, 3:22 pm, Junkone wrote: > hello > for some reason, the Date.strptime is mixing up my date. pl see here. > the date changs from "6/13/2008" to  "2020-06-13" > > irb(main):001:0> require 'date' > => true > irb(main):006:0> entry="6/13/2008" > => "6/13/2008" > irb(main):007:0> Date.strptime(entry,'%m/%d/%y') > => # > irb(main):008:0> nowdate=Date.strptime(entry,'%m/%d/%y') > => # > irb(main):009:0> nowdate.to_s > => "2020-06-13" you ned %Y, not %y (note the capitalization). im guessing that since %y means yy, its only taking the first 2 digits of your year (20) and using that as the year.