This repository was archived by the owner on May 7, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 69
feat: add unordered sql compilation #156
Merged
Merged
Changes from 1 commit
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
498b5cd
feat: add unordered sql compilation
TrevorBergeron 5aa3137
add tests
TrevorBergeron eabcdcf
Merge remote-tracking branch 'github/main' into orderingmode3
TrevorBergeron 8edabcf
fix tests
TrevorBergeron 449ca10
fix tests
TrevorBergeron 7b38280
more tests, prettier sql
TrevorBergeron 158b92d
Merge remote-tracking branch 'github/main' into orderingmode3
TrevorBergeron 91845e4
Merge remote-tracking branch 'github/main' into orderingmode3
TrevorBergeron 1ab8e30
simplify ir classes
TrevorBergeron 7a41c5a
Merge remote-tracking branch 'github/main' into orderingmode3
TrevorBergeron 57f8bc2
fix missing return statement
TrevorBergeron 43430fc
fix unary op bug
TrevorBergeron 5fc62fc
fix flaky test, add more unordered tests
TrevorBergeron 5d1e087
Merge branch 'main' into orderingmode3
TrevorBergeron 86642c4
Merge remote-tracking branch 'github/main' into orderingmode3
TrevorBergeron 2481959
Merge remote-tracking branch 'github/main' into orderingmode3
TrevorBergeron 8b7afb5
rename _compile to _compile_unordered for arrayvalue
TrevorBergeron 146b74c
fix mypy issue on join how arg
TrevorBergeron fd77028
Merge branch 'main' into orderingmode3
TrevorBergeron File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix unary op bug
- Loading branch information
commit 43430fc3920187c1459480430247d5b6627fd3cd
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 |
|---|---|---|
|
|
@@ -138,11 +138,17 @@ def _reproject_to_table(self: T) -> T: | |
| ... | ||
|
|
||
| def project_unary_op( | ||
| self: T, column_name: str, op: ops.UnaryOp, output_name=None | ||
| self: T, | ||
| input_column_id: str, | ||
| op: ops.UnaryOp, | ||
| output_column_id: typing.Optional[str] = None, | ||
| ) -> T: | ||
| """Creates a new expression based on this expression with unary operation applied to one column.""" | ||
| value = op._as_ibis(self._get_ibis_column(column_name)).name(output_name) | ||
| return self._set_or_replace_by_id(output_name, value) | ||
| result_id = ( | ||
| output_column_id or input_column_id | ||
| ) # overwrite input if not output id provided | ||
| value = op._as_ibis(self._get_ibis_column(input_column_id)).name(result_id) | ||
| return self._set_or_replace_by_id(result_id, value) | ||
|
|
||
| def project_binary_op( | ||
| self: T, | ||
|
|
@@ -258,7 +264,6 @@ def _to_ibis_expr( | |
| expose_hidden_cols: bool = False, | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Might be able to remove this parameter.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This parameter is a bit tricky, as its mostly there to prevent ibis from doing to many re-projections. I don't want to risk removing this in this cl |
||
| fraction: Optional[float] = None, | ||
| col_id_overrides: typing.Mapping[str, str] = {}, | ||
| **kwargs, | ||
| ): | ||
| """ | ||
| Creates an Ibis table expression representing the DataFrame. | ||
|
|
@@ -1061,7 +1066,6 @@ def _to_ibis_expr( | |
| col_id_overrides: typing.Mapping[str, str] = {}, | ||
| ordering_mode: Literal["string_encoded", "offset_col", "unordered"], | ||
| order_col_name: Optional[str] = ORDER_ID_COLUMN, | ||
| **kwargs, | ||
| ): | ||
| """ | ||
| Creates an Ibis table expression representing the DataFrame. | ||
|
|
||
This file contains hidden or 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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.