Autocoder

Power BI Interview Questions and Answers

Last updated 2026-11-19

Power BI interviews for analyst roles revolve around three things: modelling (star schema and relationships), DAX (measures, filter context and time intelligence) and delivery (refresh, security and performance). The hardest questions are about filter context, because most wrong DAX comes from not knowing which filters apply to a calculation.

The answers below give DAX that you can paste into a model with a Sales table and a marked Date table. For the wider analyst picture, including SQL and cases, see how to crack the data analyst interview, and for the other main BI tool see Tableau interview questions.

Typical roundsModelling and DAX questions, dashboard case, SQL, managerial
Core skillsDAX, Power Query, star schema, RLS, performance
Questions here14 worked questions

Assumed model for the DAX examples

A Sales fact table with OrderID, ProductKey, CustomerKey, OrderDate, Quantity and UnitPrice; a Product dimension; and a Date dimension marked as the date table, related one-to-many to Sales on OrderDate. Measures are written as [Total Sales] and similar names.

What interviewers probe

Power BI Interview Questions and Answers: questions with worked answers

  1. 1

    What is the difference between a calculated column and a measure?

    easy

    A calculated column is computed row by row at refresh time and stored in the model, so it uses memory and can be used on axes, slicers and rows. A measure is computed at query time for the current filter context and stores nothing. Use measures for aggregations such as totals and ratios, and columns for attributes you need to slice by, like an age band. A common mistake is putting a ratio in a column, which then sums or averages incorrectly in visuals.

    dax
    -- measure: reacts to filters
    Total Sales = SUMX ( Sales, Sales[Quantity] * Sales[UnitPrice] )
    -- calculated column: fixed per row at refresh
    Line Amount = Sales[Quantity] * Sales[UnitPrice]
  2. 2

    Explain Import, DirectQuery and composite models.

    medium

    Import loads data into the in-memory VertiPaq engine, giving the fastest visuals and full DAX support, limited by dataset size and refresh schedule. DirectQuery leaves data at the source and sends queries at view time, which gives fresh data and avoids size limits but is slower, depends on the source performance and restricts some DAX and Power Query features. A composite model mixes both, for example a large fact table in DirectQuery and small dimensions imported, often with aggregation tables to keep common queries fast.

  3. 3

    What is the difference between row context and filter context?

    hard

    Row context means a calculation is evaluated for one row, as in a calculated column or inside an iterator such as SUMX. Filter context is the set of filters from slicers, visual axes, page and report filters and CALCULATE that limits which rows a measure sees. Row context does not filter other tables by itself. CALCULATE converts the current row context into an equivalent filter context (context transition), which is why a measure referenced inside a calculated column returns the total for that row's values.

  4. 4

    What does CALCULATE do? Write a measure for sales of one category regardless of the visual filter on category.

    medium

    CALCULATE evaluates an expression in a modified filter context: filters you pass either add to the existing filters or, for the same column, replace them. In the first measure below the category is forced to Bikes, overriding any category selection. In the second, REMOVEFILTERS clears the category filter so the measure shows all-category sales, which is the denominator for a share-of-total calculation.

    dax
    Bike Sales = CALCULATE ( [Total Sales], Product[Category] = "Bikes" )
    All Category Sales = CALCULATE ( [Total Sales], REMOVEFILTERS ( Product[Category] ) )
    Category Share = DIVIDE ( [Total Sales], [All Category Sales] )
  5. 5

    Write measures for year-to-date, previous-year sales and year-over-year growth.

    medium

    Time intelligence functions need a contiguous date table with one row per day, marked as the date table and related to the fact table. TOTALYTD accumulates from the start of the year to the last visible date, and SAMEPERIODLASTYEAR shifts the visible dates back one year. DIVIDE returns blank instead of an error when the denominator is zero, and the growth is (current - previous) / previous: sales of 115 against 100 give 15 percent.

    dax
    Sales YTD = TOTALYTD ( [Total Sales], 'Date'[Date] )
    Sales PY = CALCULATE ( [Total Sales], SAMEPERIODLASTYEAR ( 'Date'[Date] ) )
    YoY % = DIVIDE ( [Total Sales] - [Sales PY], [Sales PY] )
  6. 6

    Create a running total over dates.

    medium

    Replace the date filter with all dates up to the latest date in the current filter context. ALL removes the existing filter on the date column, FILTER then keeps dates up to the maximum visible one. With a monthly axis, each month shows the cumulative total up to its last day. TOTALYTD is the shortcut when the running total resets each year.

    dax
    Running Total =
    CALCULATE (
        [Total Sales],
        FILTER ( ALL ( 'Date'[Date] ), 'Date'[Date] <= MAX ( 'Date'[Date] ) )
    )
  7. 7

    What is the difference between SUM and SUMX?

    easy

    SUM adds up one column. SUMX is an iterator: it evaluates an expression for each row of a table and then adds the results. Use SUMX when the value needs row-level arithmetic, such as quantity times price, because SUM ( Sales[Quantity] ) * SUM ( Sales[UnitPrice] ) multiplies two totals and gives a wrong answer. Iterators are also how you compute averages weighted per row.

  8. 8

    Explain ALL, ALLEXCEPT and REMOVEFILTERS.

    medium

    ALL returns a whole table or column ignoring filters, and inside CALCULATE it clears those filters. ALLEXCEPT clears all filters on a table except for the columns you list, which is useful for "percent of the region total" when the region should stay filtered. REMOVEFILTERS is the clearer modern name for the clearing behaviour inside CALCULATE, because ALL is also used as a table function. Remember that ALL ignores slicers on those columns too.

    dax
    Share of Region =
    DIVIDE (
        [Total Sales],
        CALCULATE ( [Total Sales], ALLEXCEPT ( Geography, Geography[Region] ) )
    )
  9. 9

    Compare star schema and a single flat table in Power BI. Which relationship cardinalities and filter directions do you prefer?

    medium

    A star schema has a central fact table of events and surrounding dimension tables, related one-to-many with single-direction filtering from dimension to fact. It compresses better, keeps DAX simple and avoids ambiguity. A flat table repeats attributes on every row, which wastes memory. Prefer one-to-many and single direction; use bidirectional filtering sparingly because it can create ambiguous paths and slow queries. A many-to-many relationship is better replaced by a bridge table.

  10. 10

    How do you apply row-level security, and how do you test it?

    medium

    In Power BI Desktop create a role under Manage roles and add a DAX filter on a table, for example an email column matched to the signed-in user. Publish, then assign users or groups to the role in the service. Test with View as in Desktop and in the service. Dynamic security uses a mapping table of users to regions and the USERPRINCIPALNAME function so that a single role serves everyone. Workspace admins, members and contributors bypass RLS, so test with a viewer account.

    dax
    -- filter on the Region table, one role for all users
    [Email] = USERPRINCIPALNAME ()
  11. 11

    What is query folding and why does it matter?

    medium

    Query folding is when Power Query translates its steps into one native query, such as SQL, and the source does the work. It makes refresh faster and enables incremental refresh. Steps like filters, column selection, merges and group-by usually fold, while custom functions, adding an index column or some type changes can break folding. Check with View Native Query on a step, put foldable steps first and use buffering or custom code only after folding has done its work.

  12. 12

    A report is slow. How do you diagnose and fix it?

    hard

    Use Performance Analyzer to see which visual and which part (DAX query, visual display) is slow, then DAX Studio for the query plan. Typical fixes: remove unused columns and tables, reduce column cardinality (split datetime into date and time, avoid high-cardinality text), use a star schema, replace calculated columns with measures where sensible, avoid iterating over large tables with complex logic, reduce the number of visuals per page and use aggregation tables or incremental refresh for large facts. Measure before and after each change.

  13. 13

    How do you use two date columns, such as order date and ship date, with one date table?

    hard

    Keep one active relationship, for example on order date, and create an inactive relationship for ship date. Activate it inside a measure with USERELATIONSHIP, which affects only that calculation. The alternative is two date tables with role-playing names. Inactive relationships are ignored by visuals, so measures need to say which date they use.

    dax
    Sales by Ship Date =
    CALCULATE ( [Total Sales], USERELATIONSHIP ( Sales[ShipDate], 'Date'[Date] ) )
  14. 14

    Show the top 3 products by sales as a measure, and rank them.

    medium

    RANKX ranks each product by the measure in the current context and can drive a visual filter: set the rank measure less than or equal to 3 in the visual-level filter. TOPN returns a table of the best rows and is useful inside CALCULATE. Decide in advance how ties are handled, since RANKX with the default skip method gives two products rank 1 and the next rank 3.

    dax
    Product Rank = RANKX ( ALL ( Product[ProductName] ), [Total Sales], , DESC, Skip )
    Top 3 Sales = CALCULATE ( [Total Sales], TOPN ( 3, ALL ( Product[ProductName] ), [Total Sales] ) )

Frequently asked questions

Do Power BI interviews ask for SQL as well?

Usually yes for analyst roles: joins, aggregation and window functions. See the SQL guide for practice.

How much DAX is enough?

Be fluent in CALCULATE, FILTER, ALL, time intelligence, iterators and DIVIDE, and be able to explain filter context. Advanced topics such as variables and context transition are common follow-ups.

Is Power Query tested separately?

Often briefly: merging queries, unpivoting, query folding and parameters. Knowing M syntax is a plus, but understanding steps and folding is usually enough.

Power BI or Tableau: which should I learn?

Learn the one named in the job description. Concepts such as star schema, filters and dashboard design transfer between them.

Related guides

More in Role-wise Interview Questions by Job and Tech Stack

See all in this section