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.
Hey everyone,
I have been struggling for a few weeks trying to move my current reports from the Standard Calendar to our company's 4-4-5 Fiscal Calendar.
In the attached PBIX file, I have 2023 and 2024 Fiscal Calendars loaded, I have shown what the problem is, and what the expected results should be.
These reports work fantastic on the Standard Calendar, but I can not get the correct measure for my 4-4-5! Help would be extremely appreciated! If you could try your measures in the PBIX file and then send back, that would be awesome.
Here is the link to download from Google Drive:
https://drive.google.com/file/d/1rlCmeluJKptGdRL4FM6A49cocbJjSET3/view?usp=sharing
Order Value PY =
VAR _CY = SELECTEDVALUE( 'DIM-Date'[F Year] )
VAR _PY = _CY - 1
VAR _Result =
CALCULATE(
[Order Value],
'DIM-Date'[F Year] = _PY
)
RETURN
_Result
Solved! Go to Solution.
Chat GPT and I figured it out 👏 I appreciate your help
Total Sales PY =
VAR _PreviousYear = MAX('DIM-Date'[F Year]) - 1
VAR _CurrentDayOfYear = VALUES('DIM-Date'[F Day of Year])
RETURN
CALCULATE(
[Total Sales],
FILTER(
ALL('DIM-Date'),
'DIM-Date'[F Year] = _PreviousYear &&
'DIM-Date'[F Day of Year] IN _CurrentDayOfYear
)
)
. It was the use of the VALUES function to create a virtual table and the IN function.
Hi @tkramer ,
You can create a measure.
Measure 3 =
VAR _CY = MAX( 'DIM-Date'[F Year] )
VAR _PY = _CY - 1
VAR _Result =
CALCULATE(
[Order Value],
FILTER(ALL('DIM-Date'),'DIM-Date'[F Year] = _PY && 'DIM-Date'[F Day of Year] =MAX('DIM-Date'[F Day of Year]))
)
RETURN
_Result
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
This Total on the bottom right does not sum correctly. It is only populating 1.2M.
Chat GPT and I figured it out 👏 I appreciate your help
Total Sales PY =
VAR _PreviousYear = MAX('DIM-Date'[F Year]) - 1
VAR _CurrentDayOfYear = VALUES('DIM-Date'[F Day of Year])
RETURN
CALCULATE(
[Total Sales],
FILTER(
ALL('DIM-Date'),
'DIM-Date'[F Year] = _PreviousYear &&
'DIM-Date'[F Day of Year] IN _CurrentDayOfYear
)
)
. It was the use of the VALUES function to create a virtual table and the IN function.
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 |
---|---|
80 | |
79 | |
60 | |
36 | |
33 |
User | Count |
---|---|
91 | |
59 | |
59 | |
49 | |
42 |