Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
Hi all,
I have a requirement to show data based on selection (week to date, month to date, financial quarter to date, financial half year to date and financial year to date) on a card visual as well as on the bar chart that shows last 12 weeks (for week to date), last 12 months (for month to date), last 4 financial quarter (for financial quarter todate) etc.
I have managed to create a measure that give meaccurate results for the card visuals however am struggling to get the same on the column chart that shows last 12 weeks (for WTD), last 12 months (for MTD) etc. data!
Here what I have done so far:
A stand alone time series table as per below:
TVS | Order |
WTD (Week To Date) | 1 |
MTD (Month To Date) | 2 |
FQTD (Financial Quarter To Date) | 3 |
FHYTD (Financial Half Year To Date) | 4 |
FYTD (FInancial Year To Date) | 5 |
Custom Date Range | 6 |
Calendar dimention table:
In my Calendar dimention table I have created columns that returns, WTD - Start Date, MTD - Start Date and so on that gives me a start dates based on the current date.
Fact table:
My fact table is in active relation with Calendar table via chk date to date column in the Calendar table. This chk date column has the current date.
I need to get the count of total applications based on its capture date that is also available in my fact table.
I have created a flag within my fact table as per below:
IsWTD flag = if(capture date >= RELATED(CalendarTable[WTD - Start Date]) && capture date <= RELATED(CalendarTable[TimeSeries - End]),"Y","N")
The above flag will be used in a mesure that execute the count as per below:
sub_presub_output =
var tsselected = SELECTEDVALUE(TimeSeriesValues[TSV])
var sub_presub_WTDCount =
calculate(DISTINCTCOUNT(FactTable[applncation_key]),
FactTable[Captr Date] <> BLANK()
&&
FactTable[IsWTD flag] = "Y")
first, try to use the filter pane for each visual and select the date. There is a relative date function in the filter view pane to help select last x <week,month, etc.>
Thanks @3CloudThomas
My time series table is a stand alone table and not linked with the date table. My measeure giving me a correct overall result but it is not being split out for the last 12 weeks! I tried using a relevant date from my fact table and use it as filter to user relative date function but still no luck!
Please advise.
Thanks
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
94 | |
86 | |
81 | |
70 | |
49 |
User | Count |
---|---|
143 | |
124 | |
107 | |
60 | |
55 |