Adds MotherDuck support to DuckDB native fdw. #511
Merged
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.
What kind of change does this PR introduce?
Adds support for MotherDuck as a remote server type in the DuckDB fdw.
What is the current behavior?
MotherDuck is not currently supported.
What is the new behavior?
or using vault secrets
Additional context
MotherDuck is remote DuckDB instance that gets ATTACHed to the local one so we're able to honor the LIMIT TO / EXCEPT table list arguments to
IMPORT FOREIGN SCHEMAby pushing them down to the query agains the remote information_schema.MotherDuck doesn't use a DuckDB secret block, instead it relies on env vars (not relevant here) or configuration settings. Despite what the docs say, passing those settings as url params to the first argument to ATTACH doesn't seem to work any longer.
The test coverage is limited at the moment because afaik there isn't an emulator for md. One potential improvement would be to also add support for attaching to a remote duckdb file on s3 which would share most of this functionality other than the configuration logic. i.e. https://duckdb.org/docs/stable/guides/network_cloud_storage/duckdb_over_https_or_s3
Happy to update the docs accordingly if this change is workable.