Grouping rows together #1145
richb-hanover
started this conversation in
General
Replies: 1 comment 3 replies
-
I don't think there's anything in PRQL that would make this especially terse. Indeed, until we have #504, forming the groups will likely require an s-string with a So, yes, I think this is probably more of a SQL question — create a column with the bins, then do the aggregations grouping by the bins. Sorry not to be more helpful! |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm going to display my shallow SQL knowledge here. Maybe this is simply an SQL question...
I have a table that contains property values and tax bills for this year and previous years. I would like to build a query that displays some statistics (average change in price between last year and this, average change in tax bills, etc) and outputs a table with rows for separate ranges of property values:
0-$100K
$100K - $250K
$250K - $500K
$500K - $1M
... etc.
I don't really know how to make such a single query in SQL, but I wondered if PRQL offers any facility for doing this.
Or is this simply magical thinking? :-)
Beta Was this translation helpful? Give feedback.
All reactions