{"record":{"id":"efae34b6f8521a37","repo":"apache/shardingsphere","slug":"23","errorCode":"23","errorMessage":"Identifier '%s' is ambiguous, matched actual identifiers: %s.","messagePattern":"Identifier '(.+?)' is ambiguous, matched actual identifiers: (.+?)\\.","errorType":"exception","errorClass":"AmbiguousIdentifierException","httpStatus":null,"severity":"error","filePath":"infra/common/src/main/java/org/apache/shardingsphere/infra/metadata/identifier/IdentifierIndex.java","lineNumber":207,"sourceCode":"        NormalizedBucket<T> normalizedBucket = currentSnapshot.getNormalizedBuckets().get(policy.normalizeForLookup(identifier));\n        if (null == normalizedBucket) {\n            return null;\n        }\n        return getByUnquotedNormalizedIdentifier(currentSnapshot, normalizedBucket, identifier);\n    }\n    \n    private T getByUnquotedNormalizedIdentifier(final Snapshot<T> currentSnapshot, final NormalizedBucket<T> normalizedBucket, final String identifier) {\n        if (!normalizedBucket.hasUnquotedIdentifier()) {\n            return null;\n        }\n        if (normalizedBucket.hasSingleUnquotedIdentifier()) {\n            return normalizedBucket.getSingleUnquotedValue();\n        }\n        T exactMatchedValue = findExactMatchedValue(currentSnapshot.getExactValues(), normalizedBucket.getUnquotedIdentifiers(), identifier);\n        if (null != exactMatchedValue) {\n            return exactMatchedValue;\n        }\n        throw new AmbiguousIdentifierException(identifier, normalizedBucket.getUnquotedIdentifiers());\n    }\n    \n    private Optional<T> findByQuotedNormalizedIdentifier(final Snapshot<T> currentSnapshot, final IdentifierCasePolicy policy, final IdentifierValue identifierValue) {\n        NormalizedBucket<T> normalizedBucket = currentSnapshot.getNormalizedBuckets().get(policy.normalizeForLookup(identifierValue.getValue()));\n        if (null == normalizedBucket) {\n            return Optional.empty();\n        }\n        if (normalizedBucket.hasSingleIdentifier()) {\n            return policy.matches(normalizedBucket.getSingleIdentifier(), identifierValue.getValue(), identifierValue.getQuoteCharacter())\n                    ? Optional.ofNullable(normalizedBucket.getSingleValue())\n                    : Optional.empty();\n        }\n        String matchedIdentifier = null;\n        Collection<String> ambiguousIdentifiers = null;\n        for (String each : normalizedBucket.getIdentifiers()) {\n            if (!policy.matches(each, identifierValue.getValue(), identifierValue.getQuoteCharacter())) {\n                continue;\n            }","sourceCodeStart":189,"sourceCodeEnd":225,"githubUrl":"https://github.com/apache/shardingsphere/blob/e952770a215630a3659c75d64369168cd3e26b82/infra/common/src/main/java/org/apache/shardingsphere/infra/metadata/identifier/IdentifierIndex.java#L189-L225","documentation":"Error \"Identifier '%s' is ambiguous, matched actual identifiers: %s.\" thrown in apache/shardingsphere.","triggerScenarios":"An unqualified column or identifier matches more than one actual table or column during metadata lookup in IdentifierIndex.","commonSituations":"Ambiguous column references in joins or subqueries where several tables contain the same column name; case-mismatched unquoted identifiers.","solutions":["Qualify the identifier with its schema or table so the lookup is unambiguous.","Use the exact case-sensitive identifier or quote the identifier if it was created with quotes.","Rename one of the colliding actual identifiers so names do not overlap."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e952770a215630a3659c75d64369168cd3e26b82","analyzedAt":"2026-08-14T13:54:53.392Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}