case Types.SQL_TIMESTAMP_WITH_TIME_ZONE :
zoneOffset = HsqlDateTime.getZoneMillis(calendar, millis);
// fall through
case Types.SQL_TIMESTAMP :
parameterValues[i] = new TimestampData(millis / 1000,
x.getNanos(), zoneOffset / 1000);
break;
case Types.SQL_TIME :
millis = HsqlDateTime.getNormalisedTime(millis);
parameterValues[i] = new TimeData((int) (millis / 1000),
x.getNanos(), 0);
break;
case Types.SQL_TIME_WITH_TIME_ZONE :
zoneOffset = HsqlDateTime.getZoneMillis(calendar, millis);
parameterValues[i] = new TimeData((int) (millis / 1000),
x.getNanos(), zoneOffset / 1000);
break;
case Types.SQL_DATE :
millis = HsqlDateTime.getNormalisedDate(millis);
parameterValues[i] = new TimestampData(millis / 1000);
break;
default :
throw JDBCUtil.sqlException(ErrorCode.X_42561);
}