{"record":{"id":"0b1bb93502cb362f","repo":"apache/seatunnel","slug":"tables-configs-d-query-must-be-configured-and","errorCode":null,"errorMessage":"tables_configs[%d]: 'query' must be configured and non-blank","messagePattern":"tables_configs\\[(.+?)\\]: 'query' must be configured and non-blank","errorType":"validation","errorClass":"OptionValidationException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-neo4j/src/main/java/org/apache/seatunnel/connectors/seatunnel/neo4j/source/Neo4jSourceFactory.java","lineNumber":205,"sourceCode":"        @Override\n        public String description() {\n            return \"each 'tables_configs' entry must contain a non-blank 'query' and a schema with a unique 'table'\";\n        }\n\n        @Override\n        public boolean evaluate(ReadonlyConfig config, List<Map<String, Object>> entries)\n                throws OptionValidationException {\n            if (config.getOptional(ConnectorCommonOptions.SCHEMA).isPresent()) {\n                throw new OptionValidationException(\n                        \"root-level 'schema' cannot be used with 'tables_configs'\");\n            }\n\n            Set<String> tableIds = new HashSet<>();\n            for (int i = 0; i < entries.size(); i++) {\n                Map<String, Object> entry = entries.get(i);\n                Object query = entry.get(Neo4jSourceOptions.KEY_QUERY.key());\n                if (!(query instanceof String) || ((String) query).trim().isEmpty()) {\n                    throw new OptionValidationException(\n                            \"tables_configs[%d]: 'query' must be configured and non-blank\", i);\n                }\n\n                Object schemaValue = entry.get(ConnectorCommonOptions.SCHEMA.key());\n                if (!(schemaValue instanceof Map) || ((Map<?, ?>) schemaValue).isEmpty()) {\n                    throw new OptionValidationException(\n                            \"tables_configs[%d]: 'schema' must be configured and non-empty\", i);\n                }\n\n                Object tableValue =\n                        ((Map<?, ?>) schemaValue).get(ConnectorCommonOptions.TABLE.key());\n                if (!(tableValue instanceof String) || ((String) tableValue).trim().isEmpty()) {\n                    throw new OptionValidationException(\n                            \"tables_configs[%d]: 'schema.table' must be configured and non-blank\",\n                            i);\n                }\n\n                String tableId = ((String) tableValue).trim();","sourceCodeStart":187,"sourceCodeEnd":223,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-neo4j/src/main/java/org/apache/seatunnel/connectors/seatunnel/neo4j/source/Neo4jSourceFactory.java#L187-L223","documentation":"Each entry in 'tables_configs' must contain a non-blank 'query' (Cypher) string. The factory reads the entry map by the KEY_QUERY option key and throws OptionValidationException if the value is missing, not a String, or blank after trimming. Validation happens at config-parse time, before any connection is made.","triggerScenarios":"tables_configs entry where 'query' is absent, set to a non-string value, empty string, or whitespace-only (entry.get(Neo4jSourceOptions.KEY_QUERY.key()) fails the instanceof String / trim().isEmpty() check).","commonSituations":"Typos like 'qurey' or 'queries' instead of 'query'; YAML/HOCON indentation placing query outside the entry; leaving a placeholder empty query when generating multi-table configs.","solutions":["Add a valid Cypher 'query' string to every tables_configs entry.","Check the option key spelling is exactly 'query' inside the entry map.","Trim or replace blank query values with the actual Cypher statement."],"exampleFix":"// before\ntables_configs = [\n  { schema = { table = \"person\", ... } }\n]\n// after\ntables_configs = [\n  { query = \"MATCH (n:Person) RETURN n.name AS name\", schema = { table = \"person\", ... } }\n]","handlingStrategy":"validation","validationCode":"tables_configs.eachWithIndex { entry, i ->\n  if (!(entry.query instanceof String) || entry.query.trim().isEmpty()) {\n    throw new IllegalArgumentException(\"tables_configs[${i}].query must be a non-blank Cypher string\")\n  }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Spell the option key exactly 'query' inside each entry.","Test each Cypher statement in Neo4j Browser before adding it to config.","Lint generated configs for empty placeholders."],"tags":["neo4j","config-validation","missing-query"],"backgroundTag":"missing-required-config-field","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}