I'm trying to convert a user-legible time String to an SQL-compatible String. Therefore I use the following code:

```
// User Date
    SimpleDateFormat sdf = new SimpleDateFormat("dd.MM.YYYY - HH:mm:ss");
    String dateTimeUI = sdf.format(new Date());
    System.out.println("UI: " + dateTimeUI);
    labelDatumZeit.setText(dateTimeUI);
    System.out.println("[UI]: " + dateTimeUI);

// SQL-Date
    SimpleDateFormat sdf2 = new SimpleDateFormat("dd.MM.YYYY - HH:mm:ss");
    Date d = sdf2.parse(dateTimeUI);
    sdf2.applyPattern("yyyy-MM-dd HH:mm:ss");
    dateTimeSQL = sdf2.format(d);
    System.out.println("[SQL]: " + dateTimeSQL);

```

After converting to the new format my Data always is 2012-12-31 (+ correct time). Why is that?