{"record":{"id":"aeba6d14173ef890","repo":"pentaho/pentaho-kettle","slug":"jobentrysimple-error-exception-unableloadxml","errorCode":"JobEntrySimple.Error.Exception.UnableLoadXML","errorMessage":"JobEntrySimple.Error.Exception.UnableLoadXML","messagePattern":"JobEntrySimple\\.Error\\.Exception\\.UnableLoadXML","errorType":"error_code","errorClass":"KettleXMLException","httpStatus":null,"severity":"error","filePath":"engine/src/main/java/org/pentaho/di/job/entries/simpleeval/JobEntrySimpleEval.java","lineNumber":362,"sourceCode":"      valuetype = getValueTypeByCode( Const.NVL( XMLHandler.getTagValue( entrynode, \"valuetype\" ), \"\" ) );\n      fieldname = XMLHandler.getTagValue( entrynode, \"fieldname\" );\n      fieldtype = getFieldTypeByCode( Const.NVL( XMLHandler.getTagValue( entrynode, \"fieldtype\" ), \"\" ) );\n      variablename = XMLHandler.getTagValue( entrynode, \"variablename\" );\n      mask = XMLHandler.getTagValue( entrynode, \"mask\" );\n      comparevalue = XMLHandler.getTagValue( entrynode, \"comparevalue\" );\n      minvalue = XMLHandler.getTagValue( entrynode, \"minvalue\" );\n      maxvalue = XMLHandler.getTagValue( entrynode, \"maxvalue\" );\n      successcondition =\n        getSuccessConditionByCode( Const.NVL( XMLHandler.getTagValue( entrynode, \"successcondition\" ), \"\" ) );\n      successnumbercondition =\n        getSuccessNumberConditionByCode( Const.NVL(\n          XMLHandler.getTagValue( entrynode, \"successnumbercondition\" ), \"\" ) );\n      successbooleancondition =\n        getSuccessBooleanConditionByCode( Const.NVL( XMLHandler.getTagValue(\n          entrynode, \"successbooleancondition\" ), \"\" ) );\n      successwhenvarset = \"Y\".equalsIgnoreCase( XMLHandler.getTagValue( entrynode, \"successwhenvarset\" ) );\n    } catch ( KettleXMLException xe ) {\n      throw new KettleXMLException(\n        BaseMessages.getString( PKG, \"JobEntrySimple.Error.Exception.UnableLoadXML\" ), xe );\n    }\n  }\n\n  @Override\n  public void loadRep( Repository rep, IMetaStore metaStore, ObjectId id_jobentry, List<DatabaseMeta> databases,\n    List<SlaveServer> slaveServers ) throws KettleException {\n    try {\n      valuetype = getValueTypeByCode( Const.NVL( rep.getJobEntryAttributeString( id_jobentry, \"valuetype\" ), \"\" ) );\n      fieldname = rep.getJobEntryAttributeString( id_jobentry, \"fieldname\" );\n      variablename = rep.getJobEntryAttributeString( id_jobentry, \"variablename\" );\n      fieldtype = getFieldTypeByCode( Const.NVL( rep.getJobEntryAttributeString( id_jobentry, \"fieldtype\" ), \"\" ) );\n      mask = rep.getJobEntryAttributeString( id_jobentry, \"mask\" );\n      comparevalue = rep.getJobEntryAttributeString( id_jobentry, \"comparevalue\" );\n      minvalue = rep.getJobEntryAttributeString( id_jobentry, \"minvalue\" );\n      maxvalue = rep.getJobEntryAttributeString( id_jobentry, \"maxvalue\" );\n      successcondition =\n        getSuccessConditionByCode( Const.NVL(","sourceCodeStart":344,"sourceCodeEnd":380,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/engine/src/main/java/org/pentaho/di/job/entries/simpleeval/JobEntrySimpleEval.java#L344-L380","documentation":"JobEntrySimpleEval.loadXML parses the 'simple eval' job entry's XML tags (success conditions, variable settings). Any KettleXMLException during parsing is rethrown as KettleXMLException with the localized message keyed by JobEntrySimple.Error.Exception.UnableLoadXML ('Unable to load job entry of type ... from XML node'-style text from the messages bundle).","triggerScenarios":"XMLHandler.getTagValue for tags like 'successnumbercondition', 'successbooleancondition', 'successwhenvarset' throws inside loadXML — malformed .kjb XML, null entrynode, or invalid nested content.","commonSituations":"Truncated or hand-edited .kjb files; jobs moved between Pentaho versions where tag names changed; XML escaping errors from special characters in condition values; copy-pasted node missing expected child tags.","solutions":["Validate the .kjb XML is well-formed and the simple_eval node contains the expected tags","Recreate the 'Simple Evaluation' job entry in Spoon and re-save","Restore the job file from backup/version control","Check the nested KettleXMLException cause for the exact parse error and line"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n  jobEntrySimpleEval.loadXML(entrynode, databases, metaStore);\n} catch (KettleXMLException e) {\n  logError(\"Simple Eval job entry XML invalid: \" + e.getCause().getMessage(), e);\n  // recreate the entry or restore a backup .kjb\n}","preventionTips":["Avoid hand-editing simple_eval nodes in .kjb files","Keep expected tags (successnumbercondition, successbooleancondition, successwhenvarset) intact when templating","Restore from version control after failed edits","Inspect the nested KettleXMLException cause for the exact XML error location"],"tags":["xml","parsing","job-entry","simple-eval","kettle"],"backgroundTag":"xml-parse-error","analyzedSha":"f3058517a153da500bf4551f46d79b91bf8ec552","analyzedAt":"2026-09-13T14:04:16.340Z","contentChangedAt":"2026-09-13T14:04:16.340Z","schemaVersion":2},"datasetVersion":"2026-09-20T23:17:15.980Z"}