Worker access functions in the VGI DuckDB extension
Function category
Worker access
3 functionsReach a VGI worker directly — discover the catalogs it advertises and run its table functions or table scans — without `ATTACH`ing it as a database.
Signature
Arguments (Positional)
| Argument | Type | Mode | Description |
|---|---|---|---|
Argument
worker_path
|
Type
VARCHAR
|
Mode Positional | Description |
Returns
A table with the following columns:
| Column | Type | Description |
|---|---|---|
Column
catalog
|
Type
VARCHAR
|
Description Name of the catalog as the worker advertises it. |
Column
implementation_version
|
Type
VARCHAR
|
Description Version string of the worker implementation serving this catalog. |
Column
data_version_spec
|
Type
VARCHAR
|
Description Data-version specifier the worker reports for this catalog. |
Column
attach_options
|
Type
STRUCT[]
|
Description
Options the catalog accepts on ATTACH. Each entry has name, description, type, and default_value.
|
Column
releases
|
Type
STRUCT[]
|
Description
Release history the worker advertises. Each entry has version, released_at, summary, and notes_url.
|
Column
source_url
|
Type
VARCHAR
|
Description URL of the worker's source or documentation, if provided. |
Description
List the catalogs advertised by a VGI worker, one row per catalog with its name and description. Use this to discover what a worker exposes before ATTACHing it.
SELECT * FROM vgi_catalogs('./worker');
Signature
2 overloaded forms · click to inspectArguments (Positional)
| Argument | Type | Mode | Description |
|---|---|---|---|
Argument
worker_path
|
Type
VARCHAR
|
Mode Positional | Description |
Argument
function_name
|
Type
VARCHAR
|
Mode Positional | Description |
Argument
positional_args
|
Type
ANY[]
|
Mode Positional | Description |
Arguments (Positional)
| Argument | Type | Mode | Description |
|---|---|---|---|
Argument
worker_path
|
Type
VARCHAR
|
Mode Positional | Description |
Argument
function_name
|
Type
VARCHAR
|
Mode Positional | Description |
Argument
positional_args
|
Type
ANY[]
|
Mode Positional | Description |
Argument
named_args
|
Type
ANY
|
Mode Positional | Description |
Returns
The output columns are whatever the worker-side table function function_name produces. The schema is resolved at bind time from the worker's response, so it varies by function and worker.
Dynamic schema. The output columns are determined at bind time and vary per call, so they aren't listed here.
Description
Directly execute a table function exposed by a VGI worker, without ATTACHing it as a catalog. Pass the worker executable path, the worker-side function name, the positional arguments as a LIST, and optionally a STRUCT of named arguments.
SELECT * FROM vgi_table_function('./worker', 'projected_data', [10]);
SELECT * FROM vgi_table_function('./worker', 'projected_data', [10], {'limit': 5});
Signature
Returns
The output columns mirror the schema of the attached VGI table being scanned. The schema is resolved at bind time from the worker, so it varies per table.
Dynamic schema. The output columns are determined at bind time and vary per call, so they aren't listed here.
Description
Internal: the physical scan operator for tables in an attached VGI catalog. DuckDB binds it automatically when you query a VGI table (SELECT ... FROM mycatalog.schema.table); it exists in the function list only so serialized query plans can resolve it by name. It takes no arguments and cannot be called directly — use a normal table reference instead.