Resolve synonym dependencies and fix SQL parser compatibility - #62
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c8366309ab
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (ResolveSynonymTarget(targetId, nodesById, synonymTargets) is { } underlyingId && underlyingId != targetId) | ||
| { | ||
| AddEdge(node.Id, underlyingId, dynamic); |
There was a problem hiding this comment.
Expand synonyms reached through linked servers
When a consumer references an extracted synonym through a linked server or Oracle database link, resolution enters the ViaLink branch and continues at line 418 before this expansion runs. As a result, the consumer never receives the promised dependency on the synonym's ultimate target, and any columns collected under (consumer, underlyingTarget) are discarded because that edge does not exist. Apply the synonym-target expansion to resolved linked targets before leaving that branch.
Useful? React with 👍 / 👎.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Quality resultsQuality gate: success
CLI line, branch, method, and full method coverage must each reach 100%. A missing report is shown as unavailable. See the linked run for test failures, detailed CLI/Site coverage summaries and HTML reports, and scanner results. |
Synonym definitions were extracted without target dependencies, so consumers did not contribute to the underlying object's usage or column lineage. Oracle rejected
CREATE OR REPLACE EDITIONABLE SYNONYM, SQL Server's current grammar rejected legacy statements such asRAISERROR @errno @errmsg, and database-link connection definitions produced unnecessary lineage parser warnings.This change:
EDITIONABLE/NONEDITIONABLEsynonyms and regenerates the checked-in parser with ANTLR 4.13.1. The large generated diff is parser state/ATN renumbering.Updated with main through df278c4, including the merged Oracle extraction fix from PR #61.
Validation: all repository pre-push checks passed. Release CLI tests: 966 passed, 21 existing skips; CLI coverage: 100% lines, branches, methods, and full methods. Site formatting, lint, and type checking passed; site tests: 534 passed, 1 existing skip, with 100% coverage. Regression cases cover synonym chains, cycles, missing targets, qualified names, column usage, legacy SQL, database-link parsing exclusion, and diagnostic source IDs.
Rebuild the catalog with the updated CLI to populate these relationships. Live verification against the reported databases remains pending. The photographed
extraneous input 'null'warnings still require the affected SQL for diagnosis; they are not claimed as fixed.