dask-sql icon indicating copy to clipboard operation
dask-sql copied to clipboard

[ENH] grouping implementation

Open mattf opened this issue 3 years ago • 0 comments

Is your feature request related to a problem? Please describe. queries using grouping cannot be run by dask-sql

for instance,

import dask_sql as ds
import pandas as pd

print(ds.__version__)

c = ds.Context()

c.create_table('tbl', pd.DataFrame({'x': [1, 1, 2, 2, 2], 'y': [2, 2, 1, 2, 2], 'z': [1, 3, 10, 3, 11]}))

c.sql("""
   select x, y, sum(z), grouping(x)
   from tbl
   group by x, y
""")

results in,

2022.10.1
...
NotImplementedError: Aggregation function grouping not implemented (yet).

mattf avatar Nov 22 '22 20:11 mattf