Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I have two tables: 'Deals' and 'Dates' with couple many to one inactive relationships (for example based on 'Deals'[Created Date] and 'Deals'[Won Date]).
I ran two queries in Power BI Desktop using DAX Query View:
1.
EVALUATE
{
CALCULATE(
COUNT( 'Deals'[Deal ID] ),
USERELATIONSHIP( 'Dates'[Date], 'Deals'[Won Date] ),
FILTER(
'Deals',
'Deals'[Product] = "XYZ" &&
NOT ISBLANK('Deals'[Won Date])
)
)
}
2.
EVALUATE
{
CALCULATE(
COUNT( 'Deals'[Deal ID] ),
FILTER(
'Deals',
'Deals'[Product] = "XYZ" &&
NOT ISBLANK('Deals'[Won Date])
)
)
}
I am getting two different results, which makes me wondering why if there are no outer filters applied and how does calculate work in the bacground to obtain different outputs here.
I have went through different 'How does CALCULATE work' articles but could not find one that covers my case.
Thank you in advance!
Hey @Chakravarthy,
thank you for your reply, do you know (what Im most interested in) where is the difference in the output in my two queries coming from and why is it happening?
Hi @filipbobczuk -
Please try below code:
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
14 | |
11 | |
10 | |
10 | |
10 |
User | Count |
---|---|
16 | |
13 | |
12 | |
11 | |
8 |