pentaho/pentaho-kettle · error · KettleStepException
TableOutputDialog.FailedToFindField.Message
Error message
TableOutputDialog.FailedToFindField.Message
What it means
In TableOutputDialog's field-mapping logic, for each database insert field the code looks up the matching incoming stream field via prev.searchValueMeta(info.getFieldStream()[i]). If the lookup returns null — the named stream field is not present in the row metadata — this KettleStepException (TableOutputDialog.FailedToFindField.Message) is thrown naming the missing field.
Solutions
- Reopen the Table Output dialog and rebuild the field mapping (or use 'Enter mapping'/'Get fields' again)
- Fix the upstream step so it produces the expected field name
- Remove or remap the stale field in the Table Output mapping grid
- Verify with 'Preview' on the previous step which fields actually arrive
Example fix
// before: mapping expects field "cust_name"
String[] fieldStream = { "cust_name" }; // upstream renamed to customer_name -> throws
// after
String[] fieldStream = { "customer_name" }; // remapped to current upstream field Defensive patterns
Strategy: validation
Validate before calling
// Java: verify every mapped field exists in the incoming stream before applying
for ( String field : info.getFieldStream() ) {
if ( prev.searchValueMeta( field ) == null ) throw new IllegalStateException( "Missing field: " + field );
} Type guard
boolean allFieldsPresent = java.util.Arrays.stream( info.getFieldStream() ).allMatch( f -> prev.searchValueMeta( f ) != null );
Try / catch
try { applyMapping(); } catch ( KettleStepException e ) { new ErrorDialog( shell, "Mapping failed", "Field not found in input", e ); } Prevention
- Rebuild Table Output field mappings after upstream schema changes
- Use 'Get fields' to regenerate mappings instead of manual entry
- Preview upstream output to confirm field names before mapping
When it happens
Trigger: Opening/applying the Table Output dialog when a saved field mapping references an input stream field that no longer exists (renamed, removed upstream, or field order/type changed and cache is stale).
Common situations: Upstream step renamed a field after Table Output was configured; deleted a column; switching table output mapping between transformations; stale 'Enter mapping' metadata persisted in the transformation.
Understand the failure class
Background: Record Not Found Errors: "not found", RecordNotFound, and "was not found" — what they mean and how to fix them — this error's family across 28 libraries.
Related errors
- IngresVectorWiseLoaderDialog.FailedToFindField.Message
- JsonInput.Exception.CouldnotFindField
- ScriptValuesDialogMod.Exception.CouldNotGetFields
- TableOutput.Exception.FailedToFindField
- TableOutput.Exception.FieldRequired
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/52f857c09dd86602.
Report an issue: GitHub.
Appendix: source
Thrown at ui/src/main/java/org/pentaho/di/ui/trans/steps/tableoutput/TableOutputDialog.java:1464
int idx = prev.indexOfValue( info.getTableNameField() );
if ( idx >= 0 ) {
prev.removeValueMeta( idx );
}
}
StepMeta stepMeta = transMeta.findStep( stepname );
if ( info.specifyFields() ) {
// Only use the fields that were specified.
RowMetaInterface prevNew = new RowMeta();
for ( int i = 0; i < info.getFieldDatabase().length; i++ ) {
ValueMetaInterface insValue = prev.searchValueMeta( info.getFieldStream()[i] );
if ( insValue != null ) {
ValueMetaInterface insertValue = insValue.clone();
insertValue.setName( info.getFieldDatabase()[i] );
prevNew.addValueMeta( insertValue );
} else {
throw new KettleStepException( BaseMessages.getString(
PKG, "TableOutputDialog.FailedToFindField.Message", info.getFieldStream()[i] ) );
}
}
prev = prevNew;
}
boolean autoInc = false;
String pk = null;
// Add the auto-increment field too if any is present.
//
if ( info.isReturningGeneratedKeys() && !Utils.isEmpty( info.getGeneratedKeyField() ) ) {
ValueMetaInterface valueMeta = new ValueMetaInteger( info.getGeneratedKeyField() );
valueMeta.setLength( 15 );
prev.addValueMeta( 0, valueMeta );
autoInc = true;
pk = info.getGeneratedKeyField();
}View on GitHub (pinned to f3058517a1)