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

SQL: Fix post-aggregator naming logic for sort-project. #6250

Merged
merged 1 commit into from
Aug 28, 2018

Conversation

gianm
Copy link
Contributor

@gianm gianm commented Aug 28, 2018

The old code assumes that post-aggregator prefixes are one character
long followed by numbers. This isn't always true (we may pad with
underscores to avoid conflicts). Instead, the new code uses a different
base prefix for sort-project postaggregators ("s" instead of "p") and
uses the usual Calcites.findUnusedPrefix function to avoid conflicts.

The old code assumes that post-aggregator prefixes are one character
long followed by numbers. This isn't always true (we may pad with
underscores to avoid conflicts). Instead, the new code uses a different
base prefix for sort-project postaggregators ("s" instead of "p") and
uses the usual Calcites.findUnusedPrefix function to avoid conflicts.
@gianm
Copy link
Contributor Author

gianm commented Aug 28, 2018

This fixes a bug introduced in #5788, which is new in 0.12.3, so I think we should include this fix too.

@gianm gianm added this to the 0.12.3 milestone Aug 28, 2018
@fjy fjy merged commit 80224df into apache:master Aug 28, 2018
@gianm gianm deleted the fix-sql-sort-project-post-agg-names branch August 28, 2018 20:21
gianm added a commit to gianm/druid that referenced this pull request Aug 29, 2018
The old code assumes that post-aggregator prefixes are one character
long followed by numbers. This isn't always true (we may pad with
underscores to avoid conflicts). Instead, the new code uses a different
base prefix for sort-project postaggregators ("s" instead of "p") and
uses the usual Calcites.findUnusedPrefix function to avoid conflicts.
gianm added a commit to implydata/druid-public that referenced this pull request Aug 29, 2018
The old code assumes that post-aggregator prefixes are one character
long followed by numbers. This isn't always true (we may pad with
underscores to avoid conflicts). Instead, the new code uses a different
base prefix for sort-project postaggregators ("s" instead of "p") and
uses the usual Calcites.findUnusedPrefix function to avoid conflicts.
fjy pushed a commit that referenced this pull request Aug 29, 2018
The old code assumes that post-aggregator prefixes are one character
long followed by numbers. This isn't always true (we may pad with
underscores to avoid conflicts). Instead, the new code uses a different
base prefix for sort-project postaggregators ("s" instead of "p") and
uses the usual Calcites.findUnusedPrefix function to avoid conflicts.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants