title: java.lang.IllegalArgumentException: Parse error - Date format error?
body: <p>I am storing the current date in SQLite db using the variable CURRENT_DATE. I found that the date format used is <code>yyyy-mm-dd</code> in the same. I want to parse the date in the code but I get this error:</p>
  
  <blockquote>
    <p>java.lang.IllegalArgumentException: Parse error:
                at java.util.Date.parseError</p>
  </blockquote>
  
  <p>The code is shown below:</p>
  
  <pre><code>    SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-mm-dd");
      String formattedTaskDate = dateFormat.format(new Date(dateStoredAsStringFetchedFromDB));
      Date d = new Date(formattedTaskDate);
  </code></pre>
  
  <p>At first, I am fetching the date from the database and storing it in a String variable (because date is stored as TEXT in SQLite) and then I am performing the above operations but I get the exception as <strong>parseError</strong>.</p>
  
  <p>How can I solve this issue?</p>