-
The context here is using multiple backends and then copying the result in the in-memory DuckDB for further processing. For example, first perform a Splunk query, convert the result to a PyArrow table, and pass that table to DuckDB. Then, I want to run queries with Ibis using the Databricks SQL backend and the store resulting arrow data into the same in-memory table. How can I access the DuckDB connection that marimo uses for the default in-memory database? When using Ibis I want to avoid having to create a new connection: Looking at the source it seems you can use Line 31 in 84f263e and just pass in the duckdb module:
but then you get multiple data sources in marimo: However, these are really the same in-memory DuckDB database and if you execute the three commands below they all return the same result.
Is this the right way to do it? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
you should be able to access the default duckdb instance with just |
Beta Was this translation helpful? Give feedback.
-
This will get the connection to the same in-memory DuckDB instances marimo uses.
|
Beta Was this translation helpful? Give feedback.
Oh I see, I'm not sure what ibis does under the hood but I'd guess it makes its own connection