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

Regression test for MATERIALIZED VIEWs #47

Merged
merged 1 commit into from
Jun 25, 2024
Merged

Regression test for MATERIALIZED VIEWs #47

merged 1 commit into from
Jun 25, 2024

Conversation

mkaruza
Copy link
Collaborator

@mkaruza mkaruza commented Jun 18, 2024

  • Utility statement can do query planning. Skip Quack execution if it is starting as utility statement.

@@ -75,11 +76,13 @@ quack_utility(PlannedStmt *pstmt, const char *queryString, bool readOnlyTree, Pr
}
}

isUtilityStatement = true;
Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm not sure I follow what's happening
We set isUtilityStatement to true when we come from quack_utility, presumably PrevProcessUtilityHook ends up calling quack_planner ?

Can't we deduce from the Query that it's a utility statement?
If somewhere along the line the planner fails and we don't get back to isUtilityStatement = false we can get into a weird and hard to debug situation, no?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@Tishj you are right, it is problematic. Pushed changes so we will check ActivePortal global variable for execution

@mkaruza mkaruza force-pushed the materialized-view branch 2 times, most recently from ca8d0b7 to 775f474 Compare June 21, 2024 09:44
Copy link
Collaborator

@Tishj Tishj left a comment

Choose a reason for hiding this comment

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

LGTM

* Utility statement can do query planning. Skip Quack execution if it is
  starting as utility statement.
@mkaruza mkaruza force-pushed the materialized-view branch from 775f474 to 8d823d6 Compare June 25, 2024 07:12
@mkaruza mkaruza merged commit 5cd75ad into main Jun 25, 2024
2 checks passed
@mkaruza mkaruza deleted the materialized-view branch June 25, 2024 07:19
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.

2 participants