I have always thought that the date format simpledateformat.format (date) XXX XX XX XX XX seconds is YYYY-MM-DD HH: MM: SS, but recently discovered that the original correct way is YYY-mm. -dd hh: mm: SS, otherwise it will produce an error in 12 hours. Hereby This note.