pentaho/pentaho-kettle · error · KettleException

JobEntrySimple.Error.Exception.UnableSaveRep

JobEntrySimple.Error.Exception.UnableSaveRep

Error message

JobEntrySimple.Error.Exception.UnableSaveRep

What it means

JobEntrySimpleEval.saveRep wraps any KettleDatabaseException raised while writing the job entry's attributes ('fieldname', datatype, success condition codes, 'successwhenvarset') to the repository, rethrowing as KettleException with UnableSaveRep and the id_job. It means the job entry's configuration could not be persisted.

Solutions

  1. Check the chained KettleDatabaseException for the root SQL error (permissions, constraints, connectivity).
  2. Reconnect to the repository (re-login) and retry saving.
  3. Verify the DB user has write privileges on the job entry attribute tables.
  4. Run the repository upgrade/repair tool if the schema version mismatches.

Example fix

// before
jobEntry.saveRep(rep, metaStore, idJob); // may throw KettleException wrapping KettleDatabaseException
// after
try {
  jobEntry.saveRep(rep, metaStore, idJob);
} catch (KettleException e) {
  throw new KettleException("Persist failed for job entry; verify repository connection and write access", e);
}
Defensive patterns

Strategy: try-catch

Validate before calling

// Ensure repository is writable before save
if (rep == null || rep.isReadOnly()) throw new KettleException("Repository not writable");

Try / catch

try {
  entry.saveRep(rep, metaStore, idJob);
} catch (KettleException e) {
  logger.error("Save failed (id_job=" + idJob + "), cause=" + e.getCause(), e);
  // offer retry after reconnect
}

Prevention

When it happens

Trigger: Calling saveRep on a JobEntrySimpleEval when Repository.saveJobEntryAttribute throws KettleDatabaseException - e.g. repository connection lost, constraint violation, read-only DB user, or disk full on the repository DB.

Common situations: Saving a job when the repository session has expired; DB user lacks INSERT/UPDATE privileges on R_JOBENTRY_ATTRIBUTE; repository schema out of date after upgrade; unique-constraint clashes.

Related errors


AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13). Data as JSON: /api/errors/3631622313540612. Report an issue: GitHub.

Appendix: source

Thrown at engine/src/main/java/org/pentaho/di/job/entries/simpleeval/JobEntrySimpleEval.java:417

      rep.saveJobEntryAttribute( id_job, getObjectId(), "fieldname", fieldname );
      rep.saveJobEntryAttribute( id_job, getObjectId(), "variablename", variablename );
      rep.saveJobEntryAttribute( id_job, getObjectId(), "fieldtype", getFieldTypeCode( fieldtype ) );
      rep.saveJobEntryAttribute( id_job, getObjectId(), "mask", mask );
      rep.saveJobEntryAttribute( id_job, getObjectId(), "comparevalue", comparevalue );
      rep.saveJobEntryAttribute( id_job, getObjectId(), "minvalue", minvalue );
      rep.saveJobEntryAttribute( id_job, getObjectId(), "maxvalue", maxvalue );
      rep.saveJobEntryAttribute(
        id_job, getObjectId(), "successcondition", getSuccessConditionCode( successcondition ) );
      rep
        .saveJobEntryAttribute(
          id_job, getObjectId(), "successnumbercondition",
          getSuccessNumberConditionCode( successnumbercondition ) );
      rep.saveJobEntryAttribute(
        id_job, getObjectId(), "successbooleancondition",
        getSuccessBooleanConditionCode( successbooleancondition ) );
      rep.saveJobEntryAttribute( id_job, getObjectId(), "successwhenvarset", successwhenvarset );
    } catch ( KettleDatabaseException dbe ) {
      throw new KettleException( BaseMessages.getString( PKG, "JobEntrySimple.Error.Exception.UnableSaveRep" )
        + id_job, dbe );
    }
  }

  @Override
  public Result execute( Result previousResult, int nr ) throws KettleException {
    Result result = previousResult;

    result.setNrErrors( 1 );
    result.setResult( false );

    String sourcevalue = null;
    switch ( valuetype ) {
      case VALUE_TYPE_FIELD:
        List<RowMetaAndData> rows = result.getRows();
        RowMetaAndData resultRow = null;
        if ( isDetailed() ) {
          logDetailed( BaseMessages.getString( PKG, "JobEntrySimpleEval.Log.ArgFromPrevious.Found", ( rows != null

View on GitHub (pinned to f3058517a1)