Migrating Sql To Dbt
Automatically converts SQL queries into Dbt projects, streamlining your data transformation workflows and boosting efficiency.
Install on your platform
We auto-selected Claude Code based on this skillβs supported platforms.
Run in terminal (recommended)
claude mcp add migrating-sql-to-dbt npx -- -y @trustedskills/migrating-sql-to-dbt
Or manually add to ~/.claude/settings.json
{
"mcpServers": {
"migrating-sql-to-dbt": {
"command": "npx",
"args": [
"-y",
"@trustedskills/migrating-sql-to-dbt"
]
}
}
}Requires Claude Code (claude CLI). Run claude --version to verify your install.
About This Skill
What it does
This skill converts existing SQL queries into equivalent dbt (data build tool) models. It automates the tedious process of translating SQL logic into a more maintainable and version-controlled data transformation pipeline using dbt. The resulting dbt models can then be executed within a dbt project to generate transformed datasets.
When to use it
- You have existing SQL scripts for data transformations that you want to incorporate into a dbt workflow.
- Your team is transitioning from raw SQL to a more structured and collaborative dbt-based approach to data modeling.
- You need to quickly create dbt models from legacy SQL code without manually rewriting everything.
- You are looking for a way to standardize your data transformation logic within a dbt project.
Key capabilities
- SQL to dbt model conversion
- Automated translation of SQL queries
- Generation of dbt-compatible code
- Integration with existing dbt projects
Example prompts
- "Convert this SQL query into a dbt model:
SELECT * FROM users WHERE age > 18." - "Translate the following SQL script to dbt and create a new model named 'active_users': [SQL Script]"
- βCan you convert this stored procedure logic into a dbt model?β
Tips & gotchas
- Ensure your environment has access to the original SQL query. The skill requires the full SQL code as input.
- The converted dbt models may require some manual adjustments and testing depending on the complexity of the original SQL.
Tags
TrustedSkills Verification
Unlike other registries that point to live repositories, TrustedSkills pins every skill to a verified commit hash. This protects you from malicious updates β what you install today is exactly what was reviewed and verified.
Security Audits
| Gen Agent Trust Hub | Pass |
| Socket | Pass |
| Snyk | Pass |
π Community
Passed automated security scans.