Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skip PruneSubfieldsForComplexType with ArrayType #54430

Open
MaxWk opened this issue Dec 26, 2024 · 0 comments
Open

Skip PruneSubfieldsForComplexType with ArrayType #54430

MaxWk opened this issue Dec 26, 2024 · 0 comments
Labels
type/enhancement Make an enhancement to StarRocks

Comments

@MaxWk
Copy link
Contributor

MaxWk commented Dec 26, 2024

Enhancement

Recently, when troubleshooting an issue related to the PruneSubfieldsForComplexType optimization, I found that this optimization doesn't seem to be helpful for array types. However, MarkSubfieldsOptVisitor still processes array types and then records ComplexTypeAccessPaths. Is it possible to set array types to be skipped?

        @Override
        public Void visitVariableReference(ColumnRefOperator variable, Context context) {
            if (variable.getType().isComplexType()) {
                ComplexTypeAccessPaths accessPaths = new ComplexTypeAccessPaths(ImmutableList.copyOf(complexTypeAccessPaths));
                if (visitedAccessGroup == null) {
                    context.addAccessPaths(variable, accessPaths);
                } else {
                    /*
                     * If specific ColumnRefOperator has visited access group, we should merge it.
                     */
                    context.addAccessPaths(variable, accessPaths, visitedAccessGroup);
                }
            }
            return null;
        }
@MaxWk MaxWk added the type/enhancement Make an enhancement to StarRocks label Dec 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement Make an enhancement to StarRocks
Projects
None yet
Development

No branches or pull requests

1 participant