Could someone tell me why java convert the following date 30.06.2001
(MM.DD.YYYY) in 06.06.2003 ?

I use the followin code :

import java.util.Date;
import java.util.Calendar;
import java.text.SimpleDateFormat;
import java.text.ParsePosition;

public class DateTest
{

public DateTest()
{
}

public static void main(String[] args)
{
String sDate = "30.06.2001";
System.out.println( sDate);
SimpleDateFormat localFormatter = new SimpleDateFormat("MM.dd.yyyy");
ParsePosition pos = new ParsePosition(0);
Date myDate = localFormatter.parse(sDate, pos);
System.out.println( localFormatter.format(myDate) );
}
}

It produces the following outup :
30.06.2001
06.06.2003


Any explanation is welcomed.


--
Jean-Philippe Forti
EIM SA Switzerland
jpforti@eim.nospam (replace nospam with ch)