{"record":{"id":"b6b6ff7fcf09bb55","repo":"pentaho/pentaho-kettle","slug":"groupbymeta-exception","errorCode":"GroupByMeta.Exception.UnexpectedErrorInReadingStepInfoFromRepository","errorMessage":"GroupByMeta.Exception.UnexpectedErrorInReadingStepInfoFromRepository","messagePattern":"GroupByMeta\\.Exception\\.UnexpectedErrorInReadingStepInfoFromRepository","errorType":"exception","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"engine/src/main/java/org/pentaho/di/trans/steps/groupby/GroupByMeta.java","lineNumber":640,"sourceCode":"        groupField[ i ] = rep.getStepAttributeString( id_step, i, \"group_name\" );\n      }\n\n      boolean hasNumberOfValues = false;\n      for ( int i = 0; i < nrvalues; i++ ) {\n        aggregateField[ i ] = rep.getStepAttributeString( id_step, i, \"aggregate_name\" );\n        subjectField[ i ] = rep.getStepAttributeString( id_step, i, \"aggregate_subject\" );\n        aggregateType[ i ] = getType( rep.getStepAttributeString( id_step, i, \"aggregate_type\" ) );\n\n        if ( aggregateType[ i ] == TYPE_GROUP_COUNT_ALL\n            || aggregateType[ i ] == TYPE_GROUP_COUNT_DISTINCT || aggregateType[ i ] == TYPE_GROUP_COUNT_ANY ) {\n          hasNumberOfValues = true;\n        }\n        valueField[ i ] = rep.getStepAttributeString( id_step, i, \"aggregate_value_field\" );\n      }\n\n      alwaysGivingBackOneRow = rep.getStepAttributeBoolean( id_step, 0, \"give_back_row\", hasNumberOfValues );\n    } catch ( Exception e ) {\n      throw new KettleException( BaseMessages.getString(\n        PKG, \"GroupByMeta.Exception.UnexpectedErrorInReadingStepInfoFromRepository\" ), e );\n    }\n  }\n\n  @Override\n  public void saveRep( Repository rep, IMetaStore metaStore, ObjectId id_transformation, ObjectId id_step )\n    throws KettleException {\n    try {\n      rep.saveStepAttribute( id_transformation, id_step, \"all_rows\", passAllRows );\n      rep.saveStepAttribute( id_transformation, id_step, \"ignore_aggregate\", aggregateIgnored );\n      rep.saveStepAttribute( id_transformation, id_step, \"field_ignore\", aggregateIgnoredField );\n      rep.saveStepAttribute( id_transformation, id_step, \"directory\", directory );\n      rep.saveStepAttribute( id_transformation, id_step, \"prefix\", prefix );\n      rep.saveStepAttribute( id_transformation, id_step, \"add_linenr\", addingLineNrInGroup );\n      rep.saveStepAttribute( id_transformation, id_step, \"linenr_fieldname\", lineNrInGroupField );\n      rep.saveStepAttribute( id_transformation, id_step, \"give_back_row\", alwaysGivingBackOneRow );\n\n      for ( int i = 0; i < groupField.length; i++ ) {","sourceCodeStart":622,"sourceCodeEnd":658,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/engine/src/main/java/org/pentaho/di/trans/steps/groupby/GroupByMeta.java#L622-L658","documentation":"GroupByMeta.readRep wraps any exception from reading the step's attributes out of the repository in this KettleException. The stored GroupBy step definition in the Pentaho repository could not be loaded (attributes unread or a repository call failed).","triggerScenarios":"loadXML→? no: readRep(rep, id_step) queries step attributes (group_field, aggregate_name, aggregate_type, give_back_row, etc.) and any Repository call or attribute parse throws; caught by the catch block and rethrown.","commonSituations":"Repository database connectivity issues or schema mismatch; step attributes saved by an incompatible plugin/version; id_step pointing at a deleted or corrupted step record; repository metadata import partially failed.","solutions":["Test the repository connection and retry loading the transformation","Check the wrapped cause to identify which attribute/query failed","Verify repository schema version matches your Pentaho version (run upgrade scripts)","Re-save the GroupBy step in Spoon to rewrite its repository attributes","Restore the step from a known-good transformation export"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"// verify repository reachability before loading\nif ( !repository.isConnected() || !repository.testConnection() ) {\n  throw new IllegalStateException( \"Repository unavailable\" );\n}","typeGuard":null,"tryCatchPattern":"try {\n  transMeta.loadRep( repository, metaStore, transObjectId, null, null );\n} catch ( KettleException e ) {\n  if ( e.getMessage().contains( \"UnexpectedErrorInReadingStepInfoFromRepository\" ) ) {\n    log.error( \"GroupBy attributes unreadable for step; check repository schema/version\", e.getCause() );\n  } else { throw e; }\n}","preventionTips":["Keep repository schema in sync with Pentaho version (run upgrade scripts)","Test repository connectivity before batch loads","Re-save steps after plugin upgrades to refresh stored attributes","Maintain transformation exports as recovery copies"],"tags":["kettle","pdi","repository","metadata","groupby"],"backgroundTag":"database-query-failed","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"}