TGViewer
Data Analytics Data Analytics @sqlspecialist · 111K subscribers
Post #3130 3.16K
🎯 Interview Questions

1️⃣ What does CALCULATE() do?

It evaluates an expression after modifying the filter context.

2️⃣ What is the difference between ALL() and REMOVEFILTERS()?

Both can remove filters, but REMOVEFILTERS() clearly communicates that the intention is to remove filters.

3️⃣ What is ALLSELECTED() used for?

It helps calculate results based on the user's selected context while ignoring certain visual-level filters.

4️⃣ What is KEEPFILTERS()?

It preserves existing filters when applying additional filters.

5️⃣ What is context transition?

The conversion of row context into filter context, typically triggered by CALCULATE().

🧪 PRACTICE

Create these measures:

Total Sales

West Sales

Total Sales All Regions

Sales % of Total

Sales % of Selected Regions

Then add:

✔ Region slicer

✔ Category slicer

✔ Sales by Region chart

Change the slicers and observe how each measure behaves.

That observation is one of the best ways to understand DAX filter context.

💡 Key lesson:

Don't memorize CALCULATE().

Understand what filters exist, which filters you want to change, and what result you expect.

Double Tap ❤️ For More
  • ❤ 9
More from @sqlspecialist
  1. Oct 4, 20269️⃣ How would you calculate month-over-month growth? Sample Answer: “I would first retriev…
  2. Oct 4, 2026📊 Data Analyst Interview Series — Part 3 Guys, let's continue our Data Analyst Interview…
  3. Sep 29, 2026🔟 How would you find duplicate records in SQL? Sample Answer: "I would first identify the…
  4. Sep 29, 2026📊 Data Analyst Interview Series — Part 2 Guys, let's continue our Data Analyst Interview…
  5. Sep 29, 2026𝗙𝗥𝗘𝗘 𝗥𝗲𝘀𝗼𝘂𝗿𝗰𝗲𝘀 𝗧𝗼 𝗟𝗲𝗮𝗿𝗻 𝗔𝗜 𝗶𝗻 𝟮𝟬𝟮𝟲🚀 ​ Explore 6 free resource…
  6. Sep 29, 2026"After identifying duplicates, I investigate whether they are genuine duplicate records or…
Threads Profile ViewerView any public Threads profile without an account.Open ThreadLook →Writing with AI? Make it sound human.Metric37 rewrites AI drafts so they read naturally. Free AI detector, 1,500 words free.Try Metric37 →