# Native SQL

> Author native SQL queries with parameters (filter widgets) for the mb CLI. Native SQL is a query whose single stage is raw SQL (mbql.stage/native) instead of structured MBQL — the same query envelope, so it is pre-flight-validated and round-trips. Covers the shape, the four template-tag kinds (raw variable, field filter, snippet, card reference), the variable / optional-block / snippet / card-reference syntax, the field-filter-vs-variable decision, the field ref in a field-filter dimension, wiring a tag to a dashboard filter, and running with values. Triggers — "write a SQL question", "add a filter widget to my SQL", "parameterize this query", "use a field filter", "reference a saved question in SQL", "why does my variable return no rows".

## Facts
- Page: https://tashan.sh/capability/skill-metabase-native-sql
- tashan id: skill:metabase/native-sql
- Source: https://github.com/metabase/metabase-cli
- Type: skill
- Category: database
- tashan score: not scored (catalogued only — too little public evidence)
- Adoption: 9.0
- Upkeep: 98.0
- Freshness: 96.0
- Evidence coverage: 84% of the inputs this score can use
- Health: active
- Instruction depth: not yet graded
- License: AGPL-3.0
- Official: no

## Install

```sh
cp -r native-sql ~/.claude/skills/
```

## Security audit
Not scanned. We audit npm-published capabilities; this one has no npm package we can resolve, or has not reached the queue. This is not a clean bill of health.

---
Measured 2026-09-12 by tashan (https://tashan.sh) from public evidence. Scorer s5.
