-
Notifications
You must be signed in to change notification settings - Fork 603
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
DuckDB sqlglot backend [WIP] #6996
Closed
Closed
Changes from all commits
Commits
Show all changes
222 commits
Select commit
Hold shift + click to select a range
13f4567
feat(duckdb): initial cut of sqlglot DuckDB compiler
gforsyth ec830d6
feat(duckdb): simple and searched case support in sqlglot
gforsyth 783192f
fix(duckdb): handle base table in case statement
gforsyth 610b418
feat(duckdb): ArrayMap and ArrayFilter
gforsyth d368219
feat(duckdb): fix up window function lags and leads
gforsyth ec58560
feat(duckdb): implement current_database, list_schemas
gforsyth f6f2fee
feat(duckdb): fix xor
gforsyth b27a24f
feat(duckdb): sqlglot exprs for bitwise ops
gforsyth 9a7da6a
feat(duckdb): like, ilike, capitalize as sqlglot exprs
gforsyth 95f0e43
feat(duckdb): literal arrays -> sqlglot
gforsyth 06f4806
feat(duckdb): correct types in arrays, arraydistinct, arraysort
gforsyth 0a2692d
feat(duckdb): sqlglot cast null
gforsyth 83af08d
feat(duckdb): maps in progress...
gforsyth d1f8d48
feat(duckdb): use new TypeMapper class for parsing dtypes
gforsyth 1863b79
feat(duckdb): improved map support
gforsyth 7b3a208
fix(duckdb): few type conversion updates
gforsyth 760e926
feat(duckdb): quantile and multiquantile
gforsyth 131e905
feat(duckdb): countdistinct and approxcountdistinct
gforsyth a2bbae8
feat(duckdb): substring sg expr
gforsyth 954fd7c
fix(duckdb): handle sum of comparisons using count
gforsyth 7b9381e
refactor(duckdb): remove remainder of serialize
gforsyth 805aceb
fix(duckdb): nullability in _metadata
gforsyth b07a496
refactor(duckdb): redo string ops in sqlglot expressions
gforsyth acb30fd
fix(duckdb): round
gforsyth 570ae7e
fix(duckdb): fix up some date/timestamp stuff re: sqlglot
gforsyth d70cc50
fix(duckdb): pass timezones as expressions
gforsyth 84905ce
fix(duckdb): remove stringified casts
gforsyth ad288d2
feat(duckdb): bit aggregations
gforsyth d65fd3b
feat(duckdb): variance, covariance, stddev aggregation
gforsyth e0c771b
fix(duckdb): only corr_pop, no corr_samp
gforsyth 8198089
feat(duckdb): group_concat!
gforsyth dfcd711
feat(duckdb): median and fix count star
gforsyth 42d69dc
fix(duckdb): handle boolean comparisons to corr
gforsyth a0b753d
feat(duckdb): make sure any and all handle filters
gforsyth eda2f8d
feat(duckdb): port all reg functions to sqlglot
gforsyth d4d802c
fix(duckdb): all substring slicing works!
gforsyth fe9052f
fix(duckdb): handle negative bounds in arrayslice
gforsyth a9bca69
refactor(duckdb): rearrange and organize by op type
gforsyth a326c4c
fix(duckdb): strict dtype cast on numeric literal
gforsyth 5894c34
feat(duckdb): decimal infinity and nan
gforsyth 3566c4c
feat(duckdb): create_ and drop_schema
gforsyth f7924e5
feat(duckdb): use sqlglot for create table expression
gforsyth 1d29494
fix(duckdb): simplify decimal literal
gforsyth e658b60
chore(duckdb): cleanup linting errors
gforsyth d8e5e8a
fix(duckdb): fix MapGet and Map Dict
gforsyth 5f8f2ff
feat(duckdb): array repeat
gforsyth 66132ea
fix(duckdb): handle duckdb -> pandas df -> ibis table conversion
gforsyth c03859f
fix(duckdb): fix array slice with neg index > len(array)
gforsyth f9c4171
fix(duckdb): fix arrayconcat and array zip
gforsyth 35826e8
test: regen cast sql snapshots
cpcloud 73ed622
feat(duckdb): implement json getitem
cpcloud 3d7cb61
chore: fix percent_rankd and cume_dist
cpcloud cba7b01
chore: fix rowid
cpcloud dd2b981
chore: fix dynamic limit/offset
cpcloud 6c37d6c
chore: remove SUPPORTS_MAPS from upstream
cpcloud c7b9ac1
chore: fix collect with filter
cpcloud bb96a02
chore: conslidate aggregate filter application and fix reduction oper…
cpcloud 8fbb33c
chore: implement `CountDistinctStar`
cpcloud 6c201fd
chore: clean up approximate aggs and count
cpcloud f427325
chore: use sg.func in more places
cpcloud bdacfa9
chore: use `sg.exp.Tuple` instead of string formatting
cpcloud 30c5089
chore: commit ugly sql for now
cpcloud 09114e0
chore: fix scalar parameter translation
cpcloud db3ede4
chore: implement fillna
cpcloud f57ea96
chore: fix struct column construction
cpcloud 91c17b9
chore: clean up struct extract a bit
cpcloud 5eb104e
chore: use sg.exp instead of sg.expressions
cpcloud f86aa56
chore: fix inet and uuid translation
cpcloud 836acd0
chore: promote replacement values to expressions in fillna
cpcloud 2661d3c
chore: allow tuple translation in duckdb
cpcloud b10025a
chore: expressionize clip
cpcloud 61a5ba6
chore: remove duplicate TODO
cpcloud f546860
chore: clean up literal casting
cpcloud 9735605
chore: remove already-fixed comment
cpcloud 84d0411
chore: experssionize list_aggr
cpcloud 18b3773
chore: remove TODOs for TODones
cpcloud 240e943
chore: make xor a bit less annoying
cpcloud f1a1a35
chore: clean up ilike
cpcloud 7922117
revert: chore: clean up literal casting
cpcloud 75e2ec4
chore: expressionize clip
cpcloud 2cb5f12
chore: somehow the dynamic slice test is passing ... but y tho
cpcloud 59bdc67
test(duckdb): fix default backend test
cpcloud 42b177d
chore: remove sqlalchemy type annotations
cpcloud 9db9565
chore: shorten raw_sql a bit
cpcloud 80eae44
chore: clean up current_database and current_schema
cpcloud f341748
chore: fix udfs
cpcloud 9298c75
chore: remove xor mapping
cpcloud 8f14c29
revert: chore: make xor a bit less annoying
cpcloud f24bcb0
chore: comment about upstream issue
cpcloud 08c84ae
chore: implement and test `con.insert`
cpcloud 32c26d5
chore: fix all contains except InColumn
cpcloud 8cc2c68
chore: clean up `_JOIN_TYPES`
cpcloud c1bd46f
style: imports
cpcloud 2ad80f2
chore: eliminate dialect argument in duckdb sqlglot compiler
cpcloud 76bbe34
chore: lift DuckDBType.from_ibis out and fix binary literal test
cpcloud 73f276b
chore: fix macaddr literal translation
cpcloud f19d13d
chore: shorten literal translation code
cpcloud c1edafd
chore: fix literal array translation of value type
cpcloud dcef166
chore: fix approx median
cpcloud e0f50de
chore: unify decimal and non-decimal literal translation
cpcloud 5e95445
chore: fix isin/notin column
cpcloud 4d0e68d
chore: fix regexp_extract; dialect="duckdb" is required to indicate s…
cpcloud e806aa6
chore: extract sg.exp.Null() into NULL
cpcloud d2e9113
chore: move a bunch of functions to automatic registration
cpcloud 06a763e
chore: fix cume_dist translation
cpcloud dce28cb
chore: move order by keys to sqlglot construct
cpcloud f3e62bc
chore: translate window functions to sqlglot objects
cpcloud d4bdd48
chore: regen window function snapshots
cpcloud 8cd8629
chore: delete window function TODO comment
cpcloud a1d3e44
chore: implement exists/not exists
cpcloud d6657bb
chore: remove unnecessary `_FRAME_CLAUSE_NOT_ALLOWED` constant
cpcloud de6717e
chore: fix date_trunc
cpcloud 730a12f
chore: fix column order, which may be returned differently by duckdb
cpcloud 039e9bd
chore: make sure all literal -> table transformations have a consiste…
cpcloud 3d7cb7f
chore: use pandas result getter instead of branch
cpcloud 2445121
chore: reorder columns to schema order instead of forcing them to be …
cpcloud 379e033
chore: handle analytic window functions that require an order by
cpcloud f51ec45
chore: shorten code a bit
cpcloud e5e7a8d
chore: fix ms conversion
cpcloud 52bd89c
chore: xfail already xfailing test
cpcloud b5d3ec1
chore: fix intervals
cpcloud c6680e3
chore: remove explicit typeof rule
cpcloud 4f8b6d3
chore: fix casting integers to intervals
cpcloud a7ca399
chore: use arrow
cpcloud f0c0a9e
chore: fix duckdb xfail
cpcloud e5f9c88
chore: fix from_ibis decimal
cpcloud 6615b84
chore: replace `list_value` calls with `sg.exp.Array`
cpcloud 9730972
chore: use original conversion code
cpcloud 9aff71c
chore: use original conversion code
cpcloud 6207eac
INVESTIGATE BEFORE MERGE: duckdb returns dateoffsets for interval obj…
cpcloud b6f1fd0
chore: get most of dot sql tests passing
cpcloud 61b92f8
chore: avoid depending on physical table; eventually the classes shou…
cpcloud f1e9b1a
chore: let parsing fall through to sqlglot
cpcloud 8d1c119
chore: dot sql all working yay
cpcloud 7cb7990
chore: `sg.expressions` -> `sg.exp`
cpcloud cf503d7
chore: reuse `_create_temp_view`; down to a single test failure local…
cpcloud b9e3aae
chore: slightly better comment
cpcloud 17932f1
chore: remove bogus `external_tables` argument
cpcloud 9b2ffe7
chore: remove dialect from set ops
cpcloud 0fef49d
chore: remove timezone handling code; it may actually be correct, fil…
cpcloud d3f8d91
chore: get builtin agg udfs working
cpcloud 6b37361
chore: remove the need to pass where
cpcloud a23c33c
chore: clean up aggregates
cpcloud 473e331
chore: unwrap aliases in struct field access
cpcloud 207152d
chore: remove last vestiges of `Schema.apply_to`
cpcloud 9ea9f97
chore: fix strip functions
cpcloud 7635882
chore: ensure that null handling is done with IdenticalTo when `==` a…
cpcloud 544aa9d
chore: fix array concat to preserve existing behavior
cpcloud 2c3ad0a
chore: fix __xor__
cpcloud 286b3bc
chore: adjust `show_sql` doctest
cpcloud 3b464ff
chore: get outta here clickhouse
cpcloud 706d881
chore: remove a bunch of version checking in the duckdb backend
cpcloud baf7e75
chore: note why `_define_udf_translation_rules` is not necessary
cpcloud 1cb2f52
chore: avoid overkill use of arrow for current_database and current_s…
cpcloud 569eda2
chore: remove unnecessary `DuckDBTable` class
cpcloud 4572702
chore: fix broken xor
cpcloud 2014244
chore: remove `aliases or {}` pattern
cpcloud 3251285
style: rename `pieces` to `args`
cpcloud 085c212
chore: rename duplicate `_scalar_udf` rule to `_agg_udf`
cpcloud 1c4e840
chore: remove _fully_qualified_name use
cpcloud 7add166
chore: fix listing tables, schemas and databases
cpcloud c155b44
chore: make accessing schema information the same as upstream because…
cpcloud b7c9cb3
style: improve udf translation rule docstring
cpcloud 4845aa4
chore: allow running a single doctest with `just doctest`
cpcloud dca77c5
chore: handle time literals
cpcloud d1bd037
revert: chore: allow running a single doctest with `just doctest`
cpcloud 10aa6c4
chore: remove redundant str call
cpcloud 6a48731
chore: unbind in `to_sql` call to decouple backend translation
cpcloud 10729fa
chore: update for enforced naming for all expressions including literals
cpcloud 626fdc6
docs: avoid executing `.close()` as it is not necessary for the new d…
cpcloud fdf2579
chore: avoid unnecessary additional node before finding base table
cpcloud 6a582c8
chore: factor out unaliasing
cpcloud 2552790
chore: fix renaming of pandas backend single column results
cpcloud c3ef2dd
chore: fix insert by runing pre execute hooks before compiling
cpcloud 86fc6f4
chore: clean up append
cpcloud f4ee1e1
chore: consolidate under the banner of `raw_sql`
cpcloud 800d36c
chore: skip missing snowflake deps
cpcloud bc701e0
chore: handle expressions in values of replacements mapping for fillna
cpcloud f41d379
chore: handle expressions in values of replacements mapping for filln…
cpcloud de0755d
chore: handle expressions in values of replacements mapping for filln…
cpcloud 1dee6af
fixup! chore: handle expressions in values of replacements mapping fo…
cpcloud 84a7662
chore(clickhouse): force column names to match the schema because col…
cpcloud 696ecb1
chore: bring back annoying workaround for ddb 8375
cpcloud 2a9d918
chore(bigquery): force column names to match the expression schema
cpcloud c55fb67
chore(pyspark): handle intervals before raw
cpcloud 3dc9ccf
chore(snowflake): force column names to match the expression schema
cpcloud b68dfe6
test(duckdb): fix error type on extension download failure when sandb…
cpcloud 566e399
chore(deps): remove duckdb-engine from deps
cpcloud 6779ee3
fixup! chore(deps): remove duckdb-engine from deps
cpcloud 5ce93dd
ci: remove duckdb-engine from ci
cpcloud 787acdc
chore: translate the table full stop, for table array view, instead o…
cpcloud 2eab3b8
chore: handle subquery only on selects
cpcloud eeaa2aa
chore: bring back decimal warning
cpcloud 76d78ce
chore: remove unused `_sql` function
cpcloud c87f9dd
chore: avoid reprojection of dataframe when converting to ibis types
cpcloud 8bfe95b
chore: impala fix naming
cpcloud 7461847
chore: generate group by indices instead of repeating the expression
cpcloud aaa25dd
fixup! chore: generate group by indices instead of repeating the expr…
cpcloud 46c0cda
chore: remove use of `sg.condition` in favor of `sg.and_`
cpcloud fe72a41
chore: pluck out `aliases` kwarg
cpcloud 9b9b5e4
chore: remove `remove_aliases` kwarg from duckdb compiler
cpcloud d9e9484
chore(duckdb): use `sg_literal` everywhere
cpcloud 5be5c91
chore: unalias everything that should not have `expr AS name`
cpcloud 282bdfb
chore: remove rebase screwups
cpcloud 189e427
chore: bring back unalias temporarily
cpcloud 29aeac5
chore: regen sql
cpcloud f46cb0f
chore: raw_sql
cpcloud 1360eaa
chore: fix for new array function representation
cpcloud a2b848d
chore: regen passing tpch queries
cpcloud ff5855e
chore: fix clip
cpcloud 995ff19
chore: add base compiler functionality
cpcloud d61d530
chore(clickhouse): move to base compiler functionality
cpcloud fe96efc
chore(duckdb): move to base compiler functionality
cpcloud b689374
chore: get almost everything working
cpcloud ed74968
chore: regen sql
cpcloud 8676b65
chore: remove duplicate clickhouse xfail
cpcloud 9da4977
chore: remove dead code and unnecessary `lit` calls
cpcloud c50f4d8
chore: clean up kw
cpcloud 159fe97
chore: remove unalias function
cpcloud f4f4054
chore: add pattern to transform empty percent rank et al
cpcloud fcfaad8
chore(clickhouse): regen sql
cpcloud dbf34e5
chore: more lit and array cleanup
cpcloud 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
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
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
Empty file.
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,177 @@ | ||
"""ClickHouse ibis expression to sqlglot compiler. | ||
|
||
The compiler is built with a few `singledispatch` functions: | ||
|
||
1. `translate` for table expressions | ||
1. `translate` for table nodes | ||
1. `translate_rel` | ||
1. `translate_val` | ||
|
||
## `translate` | ||
|
||
### Expression Implementation | ||
|
||
The table expression implementation of `translate` is a pass through to the | ||
node implementation. | ||
|
||
### Node Implementation | ||
|
||
There's a single `ops.Node` implementation for `ops.TableNode`s instances. | ||
|
||
This function: | ||
|
||
1. Topologically sorts the expression graph. | ||
1. Seeds the compilation cache with in-degree-zero table names. | ||
1. Iterates though nodes with at least one in-degree and places the result | ||
in the compilation cache. The cache is used to construct `ops.TableNode` | ||
keyword arguments to the current translation rule. | ||
|
||
## `translate_rel` | ||
|
||
Translates a table operation given already-translated table inputs. | ||
|
||
If a table node needs to translate value expressions, for example, an | ||
`ops.Aggregation` that rule is responsible for calling `translate_val`. | ||
|
||
## `translate_val` | ||
|
||
Recurses top-down and translates the arguments of the value expression and uses | ||
those as input to construct the output. | ||
""" | ||
|
||
from __future__ import annotations | ||
|
||
from typing import TYPE_CHECKING, Any | ||
|
||
import sqlglot as sg | ||
|
||
import ibis.expr.analysis as an | ||
import ibis.expr.operations as ops | ||
import ibis.expr.types as ir | ||
from ibis.common.patterns import Call | ||
from ibis.expr.analysis import c, p, x, y | ||
|
||
if TYPE_CHECKING: | ||
from collections.abc import Mapping | ||
|
||
|
||
a = Call.namespace(an) | ||
|
||
|
||
def translate( | ||
op: ops.TableNode, | ||
*, | ||
params: Mapping[ir.Value, Any], | ||
translate_rel, | ||
translate_val, | ||
) -> sg.exp.Expression: | ||
"""Translate an ibis operation to a sqlglot expression. | ||
|
||
Parameters | ||
---------- | ||
op | ||
An ibis `TableNode` | ||
params | ||
A mapping of expressions to concrete values | ||
translate_rel | ||
Relation node translator | ||
translate_val | ||
Value node translator | ||
|
||
Returns | ||
------- | ||
sqlglot.expressions.Expression | ||
A sqlglot expression | ||
""" | ||
|
||
def _translate_node(node, *args, **kwargs): | ||
if isinstance(node, ops.Value): | ||
return translate_val(node, *args, **kwargs) | ||
assert isinstance(node, ops.TableNode) | ||
return translate_rel(node, *args, **kwargs) | ||
|
||
alias_index = 0 | ||
aliases = {} | ||
|
||
def fn(node, _, **kwargs): | ||
nonlocal alias_index | ||
|
||
result = _translate_node(node, aliases=aliases, **kwargs) | ||
|
||
if not isinstance(node, ops.TableNode): | ||
return result | ||
|
||
# don't alias the root node | ||
if node is not op: | ||
aliases[node] = f"t{alias_index:d}" | ||
alias_index += 1 | ||
|
||
if alias := aliases.get(node): | ||
try: | ||
return result.subquery(alias=alias) | ||
except AttributeError: | ||
return sg.alias(result, alias=alias) | ||
else: | ||
return result | ||
|
||
# substitute parameters immediately to avoid having to define a | ||
# ScalarParameter translation rule | ||
# | ||
# this lets us avoid threading `params` through every `translate_val` call | ||
# only to be used in the one place it would be needed: the ScalarParameter | ||
# `translate_val` rule | ||
params = {param.op(): value for param, value in params.items()} | ||
replace_literals = p.ScalarParameter >> ( | ||
lambda op, _: ops.Literal(value=params[op], dtype=op.dtype) | ||
) | ||
|
||
# rewrite cumulative functions to window functions, so that we don't have | ||
# to think about handling them in the compiler, we need only compile window | ||
# functions | ||
replace_cumulative_ops = p.WindowFunction( | ||
x @ p.Cumulative, y | ||
) >> a.cumulative_to_window(x, y) | ||
|
||
# replace the right side of InColumn into a scalar subquery for sql | ||
# backends | ||
replace_in_column_with_table_array_view = p.InColumn >> ( | ||
lambda op, _: op.__class__( | ||
op.value, | ||
ops.TableArrayView( | ||
ops.Selection( | ||
table=an.find_first_base_table(op.options), selections=(op.options,) | ||
) | ||
), | ||
) | ||
) | ||
|
||
# replace any checks against an empty right side of the IN operation with | ||
# `False` | ||
replace_empty_in_values_with_false = p.InValues(x, ()) >> c.Literal( | ||
False, dtype="bool" | ||
) | ||
|
||
replace_notexists_subquery_with_not_exists = p.NotExistsSubquery(x, y) >> c.Not( | ||
c.ExistsSubquery(x, y) | ||
) | ||
|
||
add_order_by_to_window_funcs = p.WindowFunction( | ||
p.PercentRank(x) | p.RankBase(x) | p.CumeDist(x), | ||
( | ||
p.WindowFrame(..., order_by=()) | ||
>> (lambda op, ctx: op.copy(order_by=(ctx[x],))) | ||
), | ||
) | ||
|
||
op = op.replace( | ||
replace_literals | ||
| replace_cumulative_ops | ||
| replace_in_column_with_table_array_view | ||
| replace_empty_in_values_with_false | ||
| replace_notexists_subquery_with_not_exists | ||
| add_order_by_to_window_funcs | ||
) | ||
# apply translate rules in topological order | ||
results = op.map(fn, filter=(ops.TableNode, ops.Value)) | ||
node = results[op] | ||
return node.this if isinstance(node, sg.exp.Subquery) else node |
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 |
---|---|---|
|
@@ -275,11 +275,17 @@ | |
|
||
@classmethod | ||
def _from_ibis_Decimal(cls, dtype: dt.Decimal) -> sge.DataType: | ||
if (precision := dtype.precision) is None: | ||
precision = cls.default_decimal_precision | ||
|
||
if (scale := dtype.scale) is None: | ||
scale = cls.default_decimal_scale | ||
|
||
return sge.DataType( | ||
this=typecode.DECIMAL, | ||
expressions=[ | ||
sge.DataTypeParam(this=sge.Literal.number(dtype.precision)), | ||
sge.DataTypeParam(this=sge.Literal.number(dtype.scale)), | ||
sge.DataTypeParam(this=sge.Literal.number(precision)), | ||
sge.DataTypeParam(this=sge.Literal.number(scale)), | ||
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 change is to fix an actual bug which is that we weren't handling default precision and scale when converting from ibis decimal types to sqlglot decimal types |
||
], | ||
) | ||
|
||
|
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I need to revisit the return of
raw_sql
for duckdb, it doesn't seem like it can ever be closed when using rawduckdb
.