Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
So i attempted to recreate previous year. By this I used year (date) -1, but then it went very bad. Even date(year(date)-1 , month , day) went completely bad. Entering just but year (date) does work though.
I don't have pro yet, so I can't log it at the support page. I will be given it in time, but that will take a while. You know... companies...
Is this year(date)-1 a bug?
Before there are issues
I can see 2 reasons:
1. your date column is not in the date format, possibly is in text format.
2. You are using max function and it is not returning a date. Possibly, there are "blank" in your date field.
Looking at your issues, the year(date)-1 is returning 0, and when using in a date function date(0,12,31) gives 31/12/1899 as the output.
Replace the max function as below and see if it works
test measure = date(year(date(2019,01,15)-1, 12,31)
This will atleast proof whether there is a bug or not.
@Nishantjain , first of all, the data type is indeed in date/time.
Second, see below printscreens of an example why, to my opinion, it should show the correct data.
If you know of a test I could do, or you @v-danhe-msft , I can give it a try to see if something else is wrong.
I can see that there is something wrong with your data.
- In the first screenshot, you can see the correct year in "Measure 4" against group 11666 i.e 2017
- However, in you second screenshot, "Measure 4" is blank. Assuming that "Measure 4" is the same in both the screenshot, I expect to see a year again business group 10-010-CMR but it is blank. So, if the year is blank, then your "Measure 3" will given -1.
Assuming I have understood your screenshots correctly, the dax function is doing what it is expected to do.
Also, the 2 screenshots are showing different business groups. Can you try to create a screenshot where "Measure 4" has 2017 ( or anothe year) and "Measure 3" is showing -1 against the same business group
Thanks
Fair enough. Here is the same scenario with the same data.
And yes, all columns contain the same measures/ data as before Measure 3 was added.
But you say this is how DAX works. How can a 2nd measure in the same matrix influence results of another measure? I've never seen this happen before. Not even with more complicated filter usages. Even the non measure columns are affected by 'Measure 3'.
The reason Measure 3 is giving -1, is becuase Measure 4 is blank. You need to find out why Measure 4 is blank.
Most likely, the max function you are using in Measure 4 is returning blank. I don't know why this is happening without looking at your dataset.
One thing you can do is to use the isblank function in measure 3 to check if measure 4 is blank. If it is, then return a blank. This way you can avoid getting -1
Measure 3 = if(isblank([Measure 4]), blank(), year([Measure 4]))
Hope this helps
Nishant
Both Measure 3 and Measure 4 don't point towards each other. The printscreen where Measure 3 is included has the exact same dataset, measure, visuals as the one that does not have Measure 3. The only thing I do, is drag in 'Measure 3' into the visual.
This simply should not happen.
Hi @DouweMeer ,
Based on my test, it could work on my side:
Could you please post your data to have a test if possible?
Regards,
Daniel He
@v-danhe-msft , no, can do :).
Besides... I've been several times with the following:
A Task's exception(s) were not observed either by Waiting on the Task or accessing its Exception property. As a result, the unobserved exception was rethrown by the finalizer thread.
I'll consider it to be an error on my machine and wait for the new laptop I've been promised. In the mean time I'll put my hopes on the Microsoft contact we have with our company, perhaps he knows something. Haven't heard anything yet throught that channel sadly enough. Still... hopes keep you alive :).
Hi @DouweMeer ,
Ok, if you have gotten any useful solution to solve your problem, don't forget to close this topic.
Regards,
Daniel He
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 101 | |
| 76 | |
| 56 | |
| 51 | |
| 46 |