Skip to content

Commit d6eaf74

Browse files
committed
Add example on how to use :pipeline: connection string
1 parent 4a82720 commit d6eaf74

File tree

1 file changed

+16
-0
lines changed
  • docs/website/docs/dlt-ecosystem/destinations

1 file changed

+16
-0
lines changed

docs/website/docs/dlt-ecosystem/destinations/duckdb.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,22 @@ The **duckdb://** URL above creates a **relative** path to `_storage/test_quack.
153153
Dlt supports a unique connection string that triggers specific behavior for duckdb destination:
154154
* **:pipeline:** creates the database in the working directory of the pipeline, naming it `quack.duckdb`.
155155

156+
Please see the code snippets below to showing how to use it
157+
158+
1. Via `config.toml`
159+
```toml
160+
destination.duckdb.credentials=":pipeline:"
161+
```
162+
163+
2. In Python code
164+
```py
165+
p = pipeline_one = dlt.pipeline(
166+
pipeline_name="my_pipeline",
167+
destination="duckdb",
168+
credentials=":pipeline:",
169+
)
170+
```
171+
156172
### Additional configuration
157173
Unique indexes may be created during loading if the following config value is set:
158174
```toml

0 commit comments

Comments
 (0)