INTERMEDIATEDifficulty: INTERMEDIATEStorage modes

When would you use DirectQuery instead of Import in Power BI?

Short answer

When data volume exceeds what you can import, when near-real-time is genuinely required, or when a compliance rule forbids copying the data.

Full answer

Import is the default and should stay the default. Data is compressed into VertiPaq and queries are answered in memory, which is far faster than anything DirectQuery achieves.

DirectQuery is justified in three situations:

  • Volume. The data genuinely exceeds what the capacity can hold.
  • Latency. The business requires data fresher than your refresh cadence can deliver — and "real-time" survives the question "what decision changes in the next hour?"
  • Governance. A policy forbids the data leaving the source system.

Composite models are usually the right answer in practice: import the dimensions and aggregated facts, DirectQuery the detail, and let aggregations serve most queries from memory.

What the interviewer is assessing

Interviewers are listening for whether you treat DirectQuery as a cost rather than a feature. It shifts every query to the source system, exposes you to that system's load, and restricts the DAX available.

A strong answer includes pushing back on the requirement — most "real-time" requests do not survive being asked what decision depends on the freshness.

If you get stuck

  1. Hint 1. What does Import buy you?
  2. Hint 2. What does DirectQuery cost, and who pays it?