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

fix(explore): Prevent unnecessary series limit subquery #21154

Merged
merged 4 commits into from
Aug 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ describe('Dashboard edit action', () => {
});
});
});
describe('the color scheme affects the chart colors', () => {
describe.skip('the color scheme affects the chart colors', () => {
it('should change the chart colors', () => {
openAdvancedProperties().then(() => {
clear('#json_metadata');
Expand Down
4 changes: 3 additions & 1 deletion superset/connectors/sqla/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1410,7 +1410,9 @@ def get_sqla_query( # pylint: disable=too-many-arguments,too-many-locals,too-ma
col=selected, template_processor=template_processor
)
groupby_all_columns[outer.name] = outer
if not series_column_names or outer.name in series_column_names:
if (
is_timeseries and not series_column_names
) or outer.name in series_column_names:
groupby_series_columns[outer.name] = outer
select_exprs.append(outer)
elif columns:
Expand Down
4 changes: 3 additions & 1 deletion superset/models/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -1515,7 +1515,9 @@ def get_sqla_query( # pylint: disable=too-many-arguments,too-many-locals,too-ma
col=selected, template_processor=template_processor
)
groupby_all_columns[outer.name] = outer
if not series_column_names or outer.name in series_column_names:
if (
is_timeseries and not series_column_names
) or outer.name in series_column_names:
groupby_series_columns[outer.name] = outer
select_exprs.append(outer)
elif columns:
Expand Down