ivanshamaev/de-agent-skills/dbt-trino
Claude Code and agent skill by ivanshamaev/de-agent-skills
- community
Checking that the SKILL.md file is still in the repository.
Use when writing, configuring, or optimizing dbt projects targeting Trino or Starburst — covering profiles.yml setup, all authentication methods, materializations (table/view/incremental/materialized_view/ephemeral), incremental strategies (append/merge/delete+insert), table properties (format/partitioning/sorted_by), on_schema_change, seeds, snapshots, grants, session properties, data modeling patterns (Kimball/staging/intermediate/mart), dbt project structure, tests, and CI/CD.
Install
npx vskill@latest install ivanshamaev/de-agent-skills/dbt-trinoSKILL.md
The same SKILL.md was published earlier as ivanshamaev/de-agent-skills/dbt-trino.
dbt + Trino / Starburst Engineer
When to Use
Use this skill when:
- Setting up a new dbt project targeting Trino or Starburst
- Writing or debugging
profiles.ymlconnection and authentication config - Choosing and configuring materializations for Trino models
- Implementing incremental models with append, merge, or delete+insert strategies
- Setting Iceberg/Hive/Delta table properties (format, partitioning, sorted_by) via dbt
- Designing a dbt project structure: staging → intermediate → mart layers
- Writing dbt tests, seeds, snapshots against Trino
- Configuring grants, session properties, and model contracts
- Optimising dbt build performance for large Trino tables
Installation
Supported: Trino 478+, Starburst Enterprise 477-e.1+, Starburst Galaxy.
profiles.yml
Located at ~/.dbt/profiles.yml (global) or <project_root>/profiles.yml (project-scoped).
Complete parameter reference
Authentication methods
None (dev / local Trino without auth)
LDAP (most common enterprise setup)
JWT
Kerberos
Certificate (mTLS)
OAuth (browser-based, Starburst Galaxy)
Starburst Galaxy user format
dbt Project Structure
Recommended layout for a Trino-backed dbt project:
dbt_project.yml skeleton
Materializations
View
Default. Rebuilt on every dbt run via CREATE OR REPLACE VIEW.
view_security — controls whether the view runs with the definer's or invoker's permissions:
Table
Rebuilt as a full table on every run. Use for mart-layer models queried by BI.
on_table_exists options:
| Value | Behaviour | When to use | |
|---|---|---|---|
rename | Create temp → rename old to backup → rename temp to target (default) | Standard Hive/Iceberg | |
drop | Drop then recreate | AWS Glue, Delta, Iceberg when rename fails | |
replace | CREATE OR REPLACE TABLE | Connectors that support it | |
skip | CREATE TABLE IF NOT EXISTS | Idempotent create, never overwrites |
Incremental
On first run: full CREATE TABLE AS SELECT. On subsequent runs: only new/changed rows are processed.
Incremental strategies
| Strategy | unique_key | Trino connector support | Description | |
|---|---|---|---|---|
append | not required | All | INSERT new rows only. No dedup. | |
merge | required | Iceberg, Delta (v2) | MERGE INTO: UPDATE matched rows, INSERT new ones | |
delete+insert | required | Iceberg, Hive | DELETE matching rows, then INSERT all — safe for partitioned tables |
append — simplest, no dedup:
merge — upsert (requires Iceberg format_version=2):
delete+insert — deletes rows matching unique_key then inserts; works reliably on partitioned Iceberg tables:
Incremental on Hive with partition overwrite
Enable in Trino catalog config:
Or via session property in profile:
Model:
incremental_predicates — limit target table scan
For very large target tables, restrict how much of the target Trino scans during MERGE:
DBT_INTERNAL_DEST = alias for the target table; DBT_INTERNAL_SOURCE = alias for the new data CTE.
on_schema_change
Controls behaviour when source query columns differ from target table columns:
| Value | Behaviour | |
|---|---|---|
ignore | Default. New columns silently dropped; removing columns causes run failure | |
fail | Error if schema diverges — forces explicit --full-refresh | |
append_new_columns | Adds new columns to target; keeps old columns | |
sync_all_columns | Adds new + removes dropped columns; handles type changes |
Ephemeral
Not materialised in the warehouse — inlined as a CTE in dependent models. Use for lightweight reusable transformations.
Downstream model sees it as:
Limits: cannot ref() from operations/macros; don't overuse — long CTE chains are hard to debug.
Materialized View
Backed by a Trino materialized view. dbt refreshes it on each dbt run.
Use when the connector manages refresh automatically and you want database-native incremental logic.
Table Properties
Set Iceberg/Hive/Delta table properties via the properties dict. Values are Trino SQL expressions (strings must be double-quoted to produce a SQL string literal):
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/dbt_trino/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/ivanshamaev/de-agent-skills/dbt-trino)