pentaho/pentaho-kettle · error · IllegalArgumentException
This functionality for specified format pattern has not…
Error message
This functionality for specified format pattern has not been implemented yet
What it means
SimpleTimestampFormat.formatToCharacterIterator() also rejects non-Timestamp objects when the configured pattern is not compatible with the parent SimpleDateFormat pattern. Since the Timestamp-specific pattern cannot be delegated to the super implementation, any object falls through to this IllegalArgumentException.
Solutions
- Use a plain SimpleDateFormat when you need formatToCharacterIterator and your pattern does not need Timestamp nanos support
- Use format()/parse() methods of SimpleTimestampFormat instead
- Construct SimpleTimestampFormat only with patterns it explicitly supports
Example fix
// before
new SimpleTimestampFormat("yyyy-MM-dd'T'HH:mm:ss.SSSSSS").formatToCharacterIterator(new Date());
// after
new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss").formatToCharacterIterator(new Date()); Defensive patterns
Strategy: fallback
Validate before calling
if (compatibleToSuperPattern) { /* super path OK */ } else { /* avoid formatToCharacterIterator */ } Type guard
boolean canUseCharacterIterator(SimpleTimestampFormat f, Object o) { return !(o instanceof java.sql.Timestamp); } Try / catch
try {
return fmt.formatToCharacterIterator(obj);
} catch (IllegalArgumentException e) {
LOGGER.warn("Falling back to SimpleDateFormat: " + e.getMessage());
return plainFormat.formatToCharacterIterator(toDate(obj));
} Prevention
- Use Timestamp-specific patterns only with format()/parse()
- Use plain SimpleDateFormat when you need AttributedCharacterIterator
- Encapsulate pattern choice in a formatter factory
When it happens
Trigger: formatToCharacterIterator(obj) called with a non-Timestamp obj (e.g. Date or String) while compatibleToSuperPattern is false (a Timestamp-specific pattern was supplied to the constructor).
Common situations: Using timestamp patterns like 'yyyy-MM-dd'T'HH:mm:ss.SSSSSS' with attribute-iterator formatting; generic formatter frameworks passing arbitrary objects.
Understand the failure class
Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.
Related errors
- This functionality for Timestamp object has not been…
- API coding error: please specify the conversion metadata…
- Append file in repository is not possible
- : can't be converted to a timestamp
- Can't copy within a sorted list.
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/9619e9a658fb7117.
Report an issue: GitHub.
Appendix: source
Thrown at core/src/main/java/org/pentaho/di/core/row/value/timestamp/SimpleTimestampFormat.java:302
}
dateBuffer.delete( placeholderPosition, placeholderPosition + placeHolder.length() );
return placeholderPosition;
}
/**
* See <code>SimpleDateFormat</code> description. This is dummy method to deprecate using parent implementation for
* <code>Timestamp</code> until it is not fully implemented.
*/
@Override
public AttributedCharacterIterator formatToCharacterIterator( Object obj ) {
if ( obj instanceof Timestamp ) {
throw new IllegalArgumentException(
"This functionality for Timestamp object has not been implemented yet" );
}
if ( compatibleToSuperPattern ) {
return super.formatToCharacterIterator( obj );
} else {
throw new IllegalArgumentException(
"This functionality for specified format pattern has not been implemented yet" );
}
}
/**
* Parses text from a string to produce a <code>Timestamp</code>.
* <p/>
* The method attempts to parse text starting at the index given by <code>pos</code>. If parsing succeeds, then the
* index of <code>pos</code> is updated to the index after the last character used (parsing does not necessarily use
* all characters up to the end of the string), and the parsed date is returned. The updated <code>pos</code> can be
* used to indicate the starting point for the next call to this method. If an error occurs, then the index of
* <code>pos</code> is not changed, the error index of <code>pos</code> is set to the index of the character where the
* error occurred, and null is returned.
* <p/>
* <p>This parsing operation uses the {@link SimpleDateFormat#calendar calendar} to produce a {@code Date}. All of the
* {@code calendar}'s date-time fields are {@linkplain java.util.Calendar#clear() cleared} before parsing, and the
* {@code calendar}'s default values of the date-time fields are used for any missing date-time information. For
* example, the year value of the parsed {@code Date} is 1970 with {@link java.util.GregorianCalendar} if no yearView on GitHub (pinned to f3058517a1)