{"record":{"id":"54c582e684eb117f","repo":"pentaho/pentaho-kettle","slug":"ldapinput-error-dynamicfilterfieldmissing","errorCode":"LDAPInput.Error.DynamicFilterFieldMissing","errorMessage":"LDAPInput.Error.DynamicFilterFieldMissing","messagePattern":"LDAPInput\\.Error\\.DynamicFilterFieldMissing","errorType":"validation","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"plugins/ldap/impl/src/main/java/org/pentaho/di/trans/steps/ldapinput/LDAPInput.java","lineNumber":146,"sourceCode":"    // Get row from input rowset & set row busy!\n    if ( data.readRow == null ) {\n      if ( log.isDetailed() ) {\n        logDetailed( BaseMessages.getString( PKG, \"LDAPInput.Log.FinishedProcessing\" ) );\n      }\n      setOutputDone();\n      return false;\n    }\n    if ( first ) {\n      first = false;\n\n      if ( meta.isDynamicSearch() ) {\n        if ( Utils.isEmpty( meta.getDynamicSearchFieldName() ) ) {\n          throw new KettleException( BaseMessages.getString( PKG, \"LDAPInput.Error.DynamicSearchFieldMissing\" ) );\n        }\n      }\n      if ( meta.isDynamicFilter() ) {\n        if ( Utils.isEmpty( meta.getDynamicFilterFieldName() ) ) {\n          throw new KettleException( BaseMessages.getString( PKG, \"LDAPInput.Error.DynamicFilterFieldMissing\" ) );\n        }\n      }\n\n      // Create the output row meta-data\n      data.nrIncomingFields = getInputRowMeta().size();\n      data.outputRowMeta = getInputRowMeta().clone();\n      meta.getFields( getTransMeta().getBowl(), data.outputRowMeta, getStepname(), null, null, this, repository,\n                      metaStore );\n\n      // Create convert meta-data objects that will contain Date & Number formatters\n      //\n      data.convertRowMeta = data.outputRowMeta.cloneToType( ValueMetaInterface.TYPE_STRING );\n\n      if ( meta.isDynamicSearch() ) {\n        data.indexOfSearchBaseField = getInputRowMeta().indexOfValue( meta.getDynamicSearchFieldName() );\n        if ( data.indexOfSearchBaseField < 0 ) {\n          // The field is unreachable !\n          throw new KettleException( BaseMessages.getString( PKG, \"LDAPInput.Exception.CouldnotFindField\", meta","sourceCodeStart":128,"sourceCodeEnd":164,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/plugins/ldap/impl/src/main/java/org/pentaho/di/trans/steps/ldapinput/LDAPInput.java#L128-L164","documentation":"LDAPInput.dynamicSearch() throws this when 'Use dynamic filter' is enabled but the 'dynamic filter field' name is empty. The per-row LDAP filter value must come from a named input field. This is a first-row configuration validation check, mirroring the dynamic search base check.","triggerScenarios":"meta.isDynamicFilter() is true and Utils.isEmpty(meta.getDynamicFilterFieldName()); i.e. the checkbox is on in the step dialog but no filter field was selected.","commonSituations":"Enabling dynamic filtering in a cloned step after the source field was renamed; a partially configured step saved before choosing the field.","solutions":["Select the field that holds the filter value in the 'Dynamic filter field' dropdown of the LDAP Input step.","Verify the upstream step emits that field and that it is a String.","Uncheck 'Use dynamic filter' if per-row filters are not needed."],"exampleFix":"// before\n<use_dynamic_filter>Y</use_dynamic_filter>\n<dynamic_filter_fieldname/>\n// after\n<use_dynamic_filter>Y</use_dynamic_filter>\n<dynamic_filter_fieldname>myFilterField</dynamic_filter_fieldname>","handlingStrategy":"validation","validationCode":"if (meta.isDynamicFilter() && (meta.getDynamicFilterFieldName() == null || meta.getDynamicFilterFieldName().isEmpty())) {\n  throw new IllegalStateException(\"Dynamic filter is enabled but no dynamic filter field is set\");\n}","typeGuard":null,"tryCatchPattern":"try { row = getOneRow(); } catch (KettleException e) { if (e.getMessage().contains(\"DynamicFilterFieldMissing\")) { logError(\"Select a dynamic filter field in the LDAP Input dialog\"); } throw e; }","preventionTips":["Select the filter field whenever 'Use dynamic filter' is checked","Confirm the upstream step still emits the filter field after edits","Validate step metadata programmatically before scheduling transformations"],"tags":["configuration","ldap","validation"],"backgroundTag":"missing-required-config-field","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"}