Conversation
查询引擎将业务SQL包装为 SELECT 裸列 FROM (...) AS __base__ 形态后, 结果集元数据的表名为派生表别名或空串,无法映射回物理表字段, DataAuthorizationFilter.supportColumnAuthorization 收到错误表名, 列权限/脱敏失效。 修复方式:遍历AST时为派生表(FROM/JOIN子查询)构建"输出列→物理表字段" 投影映射(DerivedTableProjection),支持多层派生链归因与单 * 展开归因; 列权限解析改为联合解析 resolveTableNameAndColumn,命中派生表别名或 表名为空/未知时沿投影归因,已知物理表及歧义场景保持原有行为不变。 Closes #212 Co-Authored-By: Claude <noreply@anthropic.com>
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #213 +/- ##
============================================
- Coverage 87.99% 87.32% -0.67%
- Complexity 2117 2156 +39
============================================
Files 210 211 +1
Lines 5756 5894 +138
Branches 370 408 +38
============================================
+ Hits 5065 5147 +82
- Misses 567 602 +35
- Partials 124 145 +21 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
查询引擎将业务SQL包装为 SELECT 裸列 FROM (...) AS base 形态后, 结果集元数据的表名为派生表别名或空串,无法映射回物理表字段,
DataAuthorizationFilter.supportColumnAuthorization 收到错误表名, 列权限/脱敏失效。
修复方式:遍历AST时为派生表(FROM/JOIN子查询)构建"输出列→物理表字段"
投影映射(DerivedTableProjection),支持多层派生链归因与单 * 展开归因;
列权限解析改为联合解析 resolveTableNameAndColumn,命中派生表别名或
表名为空/未知时沿投影归因,已知物理表及歧义场景保持原有行为不变。
Closes #212
Describe what this PR does / why we need it
Does this pull request fix one issue?
Describe how you did it
Describe how to verify it
Special notes for reviews