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

Aggregate + non-aggregate expressions can be mixed in places where they should not be allowed to #1586

Open
sgrif opened this Issue Mar 4, 2018 · 0 comments

Comments

Projects
None yet
1 participant
@sgrif
Member

sgrif commented Mar 4, 2018

We only enforce that you cannot mix aggregate/non-aggregate expressions inside of tuples, but this needs to be done everywhere. Examples of queries which are currently accepted but should not be:

foo.select(nullable_int_col + max(nullable_int_col));
sql_function!(f, F, (x: Nullable<Integer>, y: Nullable<Integer>) -> Nullable<Integer>);
foo.select(f(nullable_int_col, max(nullable_int_col));

I suspect we won't be able to fix this without reworking aggregates in a way that enables group_by support, meaning it will require a major breaking change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment