pentaho/pentaho-kettle · error · KettleStepException
TableCompareMeta.Exception.NrErrorsInnerJoinFieldNotSpecifie…
Error message
TableCompareMeta.Exception.NrErrorsInnerJoinFieldNotSpecified
What it means
Field-validation chain in TableCompareMeta.getFields: the step configuration is missing the Nr of errors-inner-join field name. getFields validates all output field settings up front and throws this KettleStepException before any rows flow.
Solutions
- Set the 'nr errors inner join field' in the step dialog (e.g. 'nr_errors_inner').
- In code, call meta.setNrErrorsInnerJoinField("nr_errors_inner").
- Fix the .ktr XML <nr_errors_inner_join_field> tag.
Example fix
// before meta.setNrErrorsLeftJoinField( "nr_errors_left" ); // after meta.setNrErrorsLeftJoinField( "nr_errors_left" ); meta.setNrErrorsInnerJoinField( "nr_errors_inner" );
Defensive patterns
Strategy: validation
Validate before calling
if ( meta.getNrErrorsInnerJoinField() == null || meta.getNrErrorsInnerJoinField().isEmpty() ) {
meta.setNrErrorsInnerJoinField( "nr_errors_inner" );
} Try / catch
try {
meta.getFields( ... );
} catch ( KettleStepException e ) {
if ( e.getMessage().contains( "NrErrorsInnerJoinFieldNotSpecified" ) ) {
meta.setNrErrorsInnerJoinField( "nr_errors_inner" );
}
} Prevention
- Set all six field names in a single builder call sequence.
- Run transformation metadata validation in CI for generated .ktr files.
- Avoid partial copies of step XML between transformations.
When it happens
Trigger: getFields(...) invoked with nrErrorsInnerJoinField null/empty — thrown at TableCompareMeta.java:389.
Common situations: Programmatic metadata construction skipping this setter; hand-edited .ktr XML; template-based transformation generation missing join-count fields.
Understand the failure class
Background: "must not be empty", "cannot be empty" — required-field validation errors across open-source libraries — this error's family across 41 libraries.
Related errors
- GetTableNames.Log.NoSchemaField
- TableCompareMeta.Exception.NrRecordsReferenceFieldNotSpecifi…
- TableCompareMeta.Exception.NrErrorsRightJoinFieldNotSpecifie…
- TableCompareMeta.Exception.NrErrorsFieldIsNotSpecified
- TableCompareMeta.Exception.NrErrorsLeftJoinFieldNotSpecified
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/46dad8523b2fe8eb.
Report an issue: GitHub.
Appendix: source
Thrown at engine/src/main/java/org/pentaho/di/trans/steps/tablecompare/TableCompareMeta.java:389
if ( Utils.isEmpty( nrErrorsField ) ) {
throw new KettleStepException( BaseMessages.getString(
PKG, "TableCompareMeta.Exception.NrErrorsFieldIsNotSpecified" ) );
}
if ( Utils.isEmpty( nrRecordsReferenceField ) ) {
throw new KettleStepException( BaseMessages.getString(
PKG, "TableCompareMeta.Exception.NrRecordsReferenceFieldNotSpecified" ) );
}
if ( Utils.isEmpty( nrRecordsCompareField ) ) {
throw new KettleStepException( BaseMessages.getString(
PKG, "TableCompareMeta.Exception.NrRecordsCompareFieldNotSpecified" ) );
}
if ( Utils.isEmpty( nrErrorsLeftJoinField ) ) {
throw new KettleStepException( BaseMessages.getString(
PKG, "TableCompareMeta.Exception.NrErrorsLeftJoinFieldNotSpecified" ) );
}
if ( Utils.isEmpty( nrErrorsInnerJoinField ) ) {
throw new KettleStepException( BaseMessages.getString(
PKG, "TableCompareMeta.Exception.NrErrorsInnerJoinFieldNotSpecified" ) );
}
if ( Utils.isEmpty( nrErrorsRightJoinField ) ) {
throw new KettleStepException( BaseMessages.getString(
PKG, "TableCompareMeta.Exception.NrErrorsRightJoinFieldNotSpecified" ) );
}
ValueMetaInterface nrErrorsValueMeta = new ValueMetaInteger( nrErrorsField );
nrErrorsValueMeta.setLength( 9 );
nrErrorsValueMeta.setOrigin( origin );
inputRowMeta.addValueMeta( nrErrorsValueMeta );
ValueMetaInterface nrRecordsReference =
new ValueMetaInteger( nrRecordsReferenceField );
nrRecordsReference.setLength( 9 );
nrRecordsReference.setOrigin( origin );
inputRowMeta.addValueMeta( nrRecordsReference );
View on GitHub (pinned to f3058517a1)