Skip to content

Conversation

@georgesittas
Copy link
Contributor

@georgesittas georgesittas commented Feb 18, 2023

Fixes #340

qualify_tables,
qualify_columns,
expand_laterals,
annotate_types,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we need to do pushdown projections here instead

and keep annotate types outside in case it doesn’t work right

Copy link
Contributor Author

@georgesittas georgesittas Feb 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Annotate types requires at least qualified columns to work properly, because it needs col.table not to be empty. I don't think it'll crash, since it just skips columns for which this isn't true:

for col in scope.columns:  # line 282 in annotate_types.py
    if not col.table:
        continue
...

However, if optimize does fail for some reason and we end up not having qualified columns, I'm not sure if it's worth running just annotate_types.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added pushdown projections.

@georgesittas georgesittas merged commit 04bf185 into main Feb 20, 2023
@georgesittas georgesittas deleted the jo/jinja_block_fixes branch February 20, 2023 16:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Double brace not represented by BLOCK_END (referenced in MacroExtractor.extract)

3 participants