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.
Given the following schema
Table: Calendar
Table: GoogleAnalytics
where the 2 tables join on the Date fields,
How do I display
I've also been asked to divide the year into other arbitrary time periods (lunar calendar, for example).
Solved! Go to Solution.
Date math is going to be your best solution here. Using that you can do things like:
You can use measures within measures, so in your fortnight calculation, you can use the result of your weekly calculation. Once you have all the numbers you need, you can create the Text display measures that look something like
Display Week = "You are " & [WeekAmount] & " days into the week."
@Ormesome wrote:
Given the following schema
Table: Calendar
- Date
- Week Number
- Fortnight Number
- Month Number
Table: GoogleAnalytics
- Date
- Web Page
- Number Of Pageviews
where the 2 tables join on the Date fields,
How do I display
- "you are 2 days into the week"?
- "you are 9 days into the fortnight"?
- "you are 31 days into the month"?
I've also been asked to divide the year into other arbitrary time periods (lunar calendar, for example).
Your questions are not quite clear for me, could you post any sample data and the expected output?
Because the 2 tables are joined there is an implicit context filter on the calendar table. I found it tricky to use DAX to calculate the number of days that have passed this fortnight when there is no data in the GA table for the first 2 days.
I have reconsidered the problem and have successfully calculated this in Power Query.
Thank you
Date math is going to be your best solution here. Using that you can do things like:
You can use measures within measures, so in your fortnight calculation, you can use the result of your weekly calculation. Once you have all the numbers you need, you can create the Text display measures that look something like
Display Week = "You are " & [WeekAmount] & " days into the week."
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 |
---|---|
61 | |
56 | |
55 | |
36 | |
34 |
User | Count |
---|---|
77 | |
73 | |
45 | |
45 | |
43 |