Query Resource
query_resourceExecute a single read-only DuckDB SELECT over one Australian open data resource to retrieve matching rows.
Instructions
Run a read-only SQL query over one tabular resource and get the rows back.
The SQL dialect is DuckDB. The resource is always exposed as the table t,
whatever the file was called. Only a single SELECT statement is permitted:
no DDL, no DML, no reading other tables or files.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sql | Yes | A single DuckDB SELECT over the table `t`. | |
| limit | No | Maximum rows to return, capped at 100. | |
| portal | No | The portal the resource belongs to. | data.gov.au |
| resource_id | Yes | From get_dataset's resources list. Must have queryable == "yes". |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||