Don't miss your chance to take the Fabric Data Engineer (DP-600) exam for FREE! Find out how by attending the DP-600 session on April 23rd (pacific time), live or on-demand.
Learn moreNext up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now
Hello,
I have 2x tables one table which collects live results the other table we would like too reference results per. week / year. In an attempt to accomplish this task I have create a DAX script which dosn't work as expected.
Listed below are 2x tables CROutages & CROresults i.e. CROresults Table is really what we are attempting to accomplish, but becaue of my lack of scripting skills the DAX script below provides total SUM of what is being collected not weekly.
Any help would be greatly appreciated,
Don
DAX Script below does not work only show total outage duration not weekly results.
Results =
CALCULATE(SUM(CROutages[Outage Duration]),
FILTER(ALL(CROutages[Week],CROutages[Year]) ,
'CROresults'[Week] <= 'Key Measures'[Reporting Week] &&
'CROutages'[Year] = YEAR(TODAY()))
)
Table(CROutages)
| Week | Outage Duration |
| 3 | 1982 |
| 4 | 213 |
| 5 | 16623 |
| 6 | 532 |
| 7 | 120 |
Table(CROresults) below is the results we are looking for
| Year | Week | Results |
| 2020 | 1 | 0 |
| 2020 | 2 | 0 |
| 2020 | 3 | 1982 |
| 2020 | 4 | 213 |
| 2020 | 5 | 16623 |
| 2020 | 6 | 532 |
| 2020 | 7 | 120 |
| 2020 | 8 | 0 |
| 2020 | 9 | 0 |
Solved! Go to Solution.
Hi @Anonymous ,
You can refer the DAX below:
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
You can refer the DAX below:
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Not sure what is the problem but I'm guessing that you need a date dimension. Look it up on the web.
Once created, it will be far easier to run these time intelligence reports.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
| User | Count |
|---|---|
| 47 | |
| 44 | |
| 39 | |
| 20 | |
| 15 |
| User | Count |
|---|---|
| 70 | |
| 68 | |
| 32 | |
| 27 | |
| 25 |