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

feat: add support for groupby-only adhoc queries #58

Merged
merged 3 commits into from
Nov 13, 2024

Conversation

serramatutu
Copy link
Collaborator

@serramatutu serramatutu commented Nov 12, 2024

This PR adds support for adhoc queries with only group_by, without a metric. This is equivalent to doing client.dimension_values("my_dimension"), but since the raw APIs support it, I thought it would be nice to keep parity here as well.

I changed the validation logic to allow this, and I added unit and integration test cases to cover it. I also changed the .pyi files so that users get LSP suggestions for this use case.

You can review by commit.

This commit adds support for group_by only adhoc queries with no
metrics. This has a similar effect to listing dimension values, and is
being added to the SDK for parity with what the ADBC and GraphQL APIs
can do already.

I changed the validation logic to allow for it, and I added test cases
for it.
This commit adds typing to the groupby only queries.
@serramatutu serramatutu force-pushed the serramatutu/query-groupby branch from 978e480 to 1e1e1a0 Compare November 12, 2024 14:49
@serramatutu
Copy link
Collaborator Author

serramatutu commented Nov 12, 2024

PS: I didn't add it to this PR since it was kind of out of scope, so I merged it without that and I'm opening this as a followup.

@serramatutu serramatutu merged commit 68151d1 into main Nov 13, 2024
8 checks passed
@serramatutu serramatutu deleted the serramatutu/query-groupby branch November 13, 2024 15:07
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