name: mcp-engine-query description: Write, review, scope, execute, and analyze DAX queries in Power BI models. Use when creating or fixing DAX queries, deciding between run_query operations, investigating performance or VertiPaq issues, testing RLS access, or discovering schema before querying.
PBI Query
Use this skill for query authoring and query analysis work. Read only the bundled references needed for the current task.
Query workflow
- Inspect schema before guessing table, column, or measure names.
- Decide whether the task is execution, performance analysis, VertiPaq inspection, or access testing.
- Keep the first query scoped and small enough to inspect safely.
- Expand only after the initial query shape is correct.
Choose the operation
- Use
executewhen the user needs query results or a validation query. - Use
analyzewhen the user needs timings, operator-level diagnosis, or performance findings. - Use
vertipaqwhen the user needs storage footprint, table size, or cardinality clues. - Use
test_accesswhen the user needs role-by-role access validation.
Author safely
- Read dax-query-guide before writing new or corrected query text.
- Prefer schema discovery with
list_modelbefore inventing names or relationships. - Keep the default query scoped with filters,
TOPN, or targeted grouping. - Add ordering for multi-row outputs so results are stable and readable.
- Treat nulls in result rows as query semantics until the model proves otherwise.
Diagnose performance
- Read query-performance-guide before interpreting timings or trace output.
- Read dax-query-plan-reference when a plan contains unfamiliar operators.
- Read vertipaq-optimization-guide when the issue looks like storage bloat or high-cardinality pressure.
- Read performance-remediation-playbook when the user wants a remediation sequence instead of isolated findings.
Reference selection
- Read dax-query-guide first for syntax, quoting rules, and DAX query structure.
- Read query-performance-guide for timings, runs, and performance interpretation.
- Read dax-query-plan-reference for plan operator definitions.
- Read vertipaq-optimization-guide for storage optimization guidance.
- Read performance-remediation-playbook for end-to-end tuning workflow.