Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Anonymous
Not applicable

DAX

Hi guys,

 

I've the following DAX Expression which is giving me an error . I'm trying to find what customers didn't renew subscription in 2018 that renewed in 2016 and 2017.

 

Any help would be most appreciated.

 

 

ListCustomers1 =
VAR T2016 =
CALCULATETABLE (
VALUES ( Renewals[Account_ID] );
Renewals[Renewal Year] = 2016
)
VAR T2017 =
CALCULATETABLE (
VALUES ( Renewals[Account_ID] );
Renewals[Renewal Year] = 2017
)
VAR T2018 =
CALCULATETABLE (
VALUES ( Renewals[Account_ID]);
Renewals[Renewal Year] = 2018
)
RETURN
EXCEPT ( INTERSECT ( T2016; T2017 ); T2018 )
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi,

 

Its p[rovbably an error with my dataset.

 

Many thanks

View solution in original post

3 REPLIES 3
v-yuta-msft
Community Support
Community Support

Hi Elterrible67,

 

The formula works well on my side. Click create a table then input the formula.

 

Sample data:

1.PNG 

 

Output table:

2.PNG 

 

Regards,

Jimmy Tao

Greg_Deckler
Super User
Super User

What is the error? Sample data. Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Hi,

 

Its p[rovbably an error with my dataset.

 

Many thanks

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.