pentaho/pentaho-kettle · error · KettleException
Unable to save notepad in repository…
Error message
Unable to save notepad in repository (id_transformation=id_transformation)
What it means
saveNotePadMeta throws this KettleException when the UPDATE/INSERT of a note pad row into R_NOTE fails with a KettleDatabaseException. The id_transformation is included to help locate which transformation's note failed to persist.
Solutions
- Check the chained KettleDatabaseException cause for the exact SQL error
- Shorten the note text / ensure it fits the R_NOTE column limits
- Verify DB connectivity and write permissions on R_NOTE
- Re-save the whole transformation after the database issue is resolved
Example fix
// before
notePad.setNote(veryLongText);
delegate.saveNotePadMeta(notePad, transId);
// after
if (veryLongText.length() > MAX_NOTE_LENGTH) { veryLongText = veryLongText.substring(0, MAX_NOTE_LENGTH); }
notePad.setNote(veryLongText);
try { delegate.saveNotePadMeta(notePad, transId); }
catch (KettleException e) { log.error("Save failed: " + e.getCause(), e); throw e; } Defensive patterns
Strategy: validation
Validate before calling
if (note.getNote() != null && note.getNote().length() > 2000) { /* truncate before save */ note.setNote(note.getNote().substring(0, 2000)); } Prevention
- Keep note text within R_NOTE column limits
- Verify DB write permissions for the repository user
- Save the note as part of the transformation save flow so failures roll back together
- Check the chained KettleDatabaseException cause when this fires
When it happens
Trigger: Calling saveNotePadMeta(notePadMeta, id_transformation) when the JDBC write fails: connection loss, R_NOTE column constraints violated (e.g. note text too long), read-only database, or schema drift.
Common situations: Very large note text exceeding column size; DB in read-only mode; network interruption during save; repository upgraded by another client mid-edit.
Related errors
- AbortMeta.Exception.UnableToSaveStepInfoToRepository
- ERROR_0003_Cannot_Save_Job_Entry
- JobEntryAddResultFilenames.UnableToSaveToRepo
- LDIFInputMeta.Exception.ErrorSavingToRepository
- Unable to load Notepad from repository (id_note=id_note)
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/5192157406a16b72.
Report an issue: GitHub.
Appendix: source
Thrown at engine/src/main/java/org/pentaho/di/repository/kdr/delegates/KettleDatabaseRepositoryNotePadDelegate.java:122
* @param rep
* @param id_transformation
* @throws KettleException
*/
public void saveNotePadMeta( NotePadMeta note, ObjectId id_transformation ) throws KettleException {
try {
Point location = note.getLocation();
int x = location == null ? -1 : location.x;
int y = location == null ? -1 : location.y;
// Insert new Note in repository
note.setObjectId( insertNote(
note.getNote(), x, y, note.getWidth(), note.getHeight(), note.getFontName(), note.getFontSize(), note
.isFontBold(), note.isFontItalic(), note.getFontColorRed(), note.getFontColorGreen(), note
.getFontColorBlue(), note.getBackGroundColorRed(), note.getBackGroundColorGreen(), note
.getBackGroundColorBlue(), note.getBorderColorRed(), note.getBorderColorGreen(), note
.getBorderColorBlue(), note.isDrawShadow() ) );
} catch ( KettleDatabaseException dbe ) {
throw new KettleException( "Unable to save notepad in repository (id_transformation="
+ id_transformation + ")", dbe );
}
}
//CHECKSTYLE:LineLength:OFF
public synchronized ObjectId insertNote( String note, long gui_location_x, long gui_location_y,
long gui_location_width, long gui_location_height, String fontname, long fontsize, boolean fontbold,
boolean fontitalic, long fontcolorred, long fontcolorgreen, long fontcolorblue, long fontbackcolorred,
long fontbackcolorgreen, long fontbackcolorblue, long fontbordercolorred, long fontbordercolorgreen,
long fontbordercolorblue, boolean drawshadow ) throws KettleException {
ObjectId id = repository.connectionDelegate.getNextNoteID();
RowMetaAndData table = new RowMetaAndData();
table.addValue( new ValueMetaInteger( KettleDatabaseRepository.FIELD_NOTE_ID_NOTE ), id );
table.addValue( new ValueMetaString( KettleDatabaseRepository.FIELD_NOTE_VALUE_STR ), note );
table.addValue( new ValueMetaInteger( KettleDatabaseRepository.FIELD_NOTE_GUI_LOCATION_X ), new Long( gui_location_x ) );
table.addValue( new ValueMetaInteger( KettleDatabaseRepository.FIELD_NOTE_GUI_LOCATION_Y ), new Long( gui_location_y ) );View on GitHub (pinned to f3058517a1)