pentaho/pentaho-kettle · error · KettleException
Rest.Exception.ParamFieldEmpty
Rest.Exception.ParamFieldEmpty
Error message
Rest.Exception.ParamFieldEmpty
What it means
Thrown in calcParameters (from processRow) with message 'Parameter field is missing!': one of the configured query parameters has an empty 'field' — the row field that supplies the parameter value is blank after environment substitution.
Solutions
- Open the REST step's parameter table and fill in the missing 'Field' column for the flagged parameter row.
- Delete parameter rows that are no longer needed.
- Verify that any variable used in the Field column is defined so it does not resolve to an empty string.
- Validate the transformation before running to catch empty parameter fields at design time.
Example fix
// before (parameter row) name="apiKey"; field="" // throws ParamFieldEmpty // after name="apiKey"; field="api_key_value"
Defensive patterns
Strategy: validation
Validate before calling
// Check every parameter entry has a field before running
for (int i = 0; i < restMeta.getParameterField().length; i++) {
String f = restMeta.getParameterField()[i];
if (f == null || f.trim().isEmpty()) {
throw new IllegalStateException("Parameter '" + restMeta.getParameterName()[i] + "' has no field set");
}
} Try / catch
try { processRow(); } catch (KettleException e) {
if (e.getMessage().contains("Parameter field is missing")) { /* fill in the parameter table */ }
throw e;
} Prevention
- Never leave the Field column blank in the parameter table; remove unused rows.
- Validate the transformation before scheduling.
- Ensure variables used as field names are defined in every environment.
When it happens
Trigger: meta.getParameterField()[i] is null/empty (Utils.isEmpty) for some parameter index i while query parameters are configured, during calcHeaders/calcParameters phase of processRow.
Common situations: Parameter table in the REST dialog has a row with the 'Field' column empty (only parameter name filled); a variable used as field name resolves to empty at runtime; parameters copied from another step with the value column cleared.
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
- ChangeFileEncoding.Error.FilenameFieldMissing
- ChangeFileEncoding.Error.TargetFilenameFieldMissing
- ColumnExists.Error.TablenameFieldMissing
- GetFilesRowsCount.Log.NoField
- GetTableNames.Log.NoSchemaField
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/16f963a9466d124b.
Report an issue: GitHub.
Appendix: source
Thrown at plugins/rest/core/src/main/java/org/pentaho/di/trans/steps/rest/Rest.java:556
}
/**
* Calculate the parameters
*
* @throws KettleException
*/
private void calcParameters() throws KettleException {
// Parameters
int nrParams = meta.getParameterField() == null ? 0 : meta.getParameterField().length;
if ( nrParams > 0 ) {
data.nrParams = nrParams;
data.paramNames = new String[ nrParams ];
data.indexOfParamFields = new int[ nrParams ];
for ( int i = 0; i < nrParams; i++ ) {
data.paramNames[ i ] = environmentSubstitute( meta.getParameterName()[ i ] );
String field = environmentSubstitute( meta.getParameterField()[ i ] );
if ( Utils.isEmpty( field ) ) {
throw new KettleException( BaseMessages.getString( PKG, "Rest.Exception.ParamFieldEmpty" ) );
}
data.indexOfParamFields[ i ] = data.inputRowMeta.indexOfValue( field );
if ( data.indexOfParamFields[ i ] < 0 ) {
throw new KettleException( BaseMessages.getString( PKG, "Rest.Exception.ErrorFindingField", field ) );
}
}
data.useParams = true;
}
int nrMatrixParams = meta.getMatrixParameterField() == null ? 0 : meta.getMatrixParameterField().length;
if ( nrMatrixParams > 0 ) {
data.nrMatrixParams = nrMatrixParams;
data.matrixParamNames = new String[ nrMatrixParams ];
data.indexOfMatrixParamFields = new int[ nrMatrixParams ];
for ( int i = 0; i < nrMatrixParams; i++ ) {
data.matrixParamNames[ i ] = environmentSubstitute( meta.getMatrixParameterName()[ i ] );
String field = environmentSubstitute( meta.getMatrixParameterField()[ i ] );
if ( Utils.isEmpty( field ) ) {View on GitHub (pinned to f3058517a1)