-
Notifications
You must be signed in to change notification settings - Fork 608
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(api): support selectors in window function
order_by
and `group…
…_by` (#9649)
- Loading branch information
Showing
5 changed files
with
60 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
from __future__ import annotations | ||
|
||
import abc | ||
from typing import TYPE_CHECKING | ||
|
||
from ibis.common.grounds import Concrete | ||
|
||
if TYPE_CHECKING: | ||
from collections.abc import Sequence | ||
|
||
import ibis.expr.types as ir | ||
|
||
|
||
class Selector(Concrete): | ||
"""A column selector.""" | ||
|
||
@abc.abstractmethod | ||
def expand(self, table: ir.Table) -> Sequence[ir.Value]: | ||
"""Expand `table` into value expressions that match the selector. | ||
Parameters | ||
---------- | ||
table | ||
An ibis table expression | ||
Returns | ||
------- | ||
Sequence[Value] | ||
A sequence of value expressions that match the selector | ||
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters