Forum Discussion
Day function not referencing dates column
- 4 years ago
Anonymous write this:
Date (Corrected) = IF(DAY([Date]) = 1, [Date] - 1, [Date]) - 4 years ago
Anonymous You are indeed in the right direction. That's why my intitial tought was to give you the code for the calculated column. You can use what I sent in the first message or create it in Power Query or in the data source.
Please don't forget to accept the relevant message as a solution for community visibility.
P.S. Check out my showcase report - got some high level stuff there. Sure you will find there a lot of cool ideas.
https://community.powerbi.com/t5/Data-Stories-Gallery/SpartaBI-Feat-Contoso-100K/td-p/2449543
Give it a thumbs up over there if you liked it 🙂
Yes I was building a measure and your formula worked! I realized however that I cannot use a measure as a primary key in a relationship to another dataset. I imagine I should actually be using a calculated column in the "Transform Data" editor, is that right?
The problem is that most of my dates in the original dataset are correctly entered as end of month, but there are 3 or 4 each month that are entered as the 1st of the following month. Hence my need to clean the data so that my visuals are accurate. I hope this makes sense. Really appreciate the help.
Anonymous You are indeed in the right direction. That's why my intitial tought was to give you the code for the calculated column. You can use what I sent in the first message or create it in Power Query or in the data source.
Please don't forget to accept the relevant message as a solution for community visibility.
P.S. Check out my showcase report - got some high level stuff there. Sure you will find there a lot of cool ideas.
https://community.powerbi.com/t5/Data-Stories-Gallery/SpartaBI-Feat-Contoso-100K/td-p/2449543
Give it a thumbs up over there if you liked it 🙂