Subject Re: AW: AW: AW: [Firebird-Java] Timezones
Author Roman Rokytskyy
> Calendar utcCalendar = new GregorianCalendar(TimeZone.getTimeZone("UTC"));
>
> java.sql.Timestamp possibleFailureLocalCorrected =
> test.decodeTimestamp(
> test.decodeTimestamp(
> test.encodeTimestamp(
> test.encodeTimestamp(tsLocal, utcCalendar))), utcCalendar);
>
> System.out.println("Date " + timeLocal.toString() + " : " +
> timeLocal.getTime() + " == " + possibleFailureLocalCorrected.getTime());
>
> Date Sun Oct 25 02:30:00 CET 2009 : 1256434200562 == 1256437800562

Ah, did not pay attention to this difference... So using UTC is broken,
but the local calendar is currently ok...

Roman