Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I've read multiple posts on this error: "SAMEPERIODLASTYEAR expects a contiguous selection when the date column comes from a table on the 1-side of a bidirectional relationship." I am still baffled by my error.
I have a simple measure for calculating fees billed:
Fees Billed = CALCULATE(SUM(FactTable[AmtBilledForSubtype]),FactTable[BillSubtype]="FEE")
I have another measure for YTD Fees:
Fees Billed YTD = TOTALYTD([Fees Billed],Table_BasicCalendarUS[DateKey])
No problems with either of these measures.
Now I want Fees Billed for the same period last year. Here is the troublesome measure:
Fees Billed SPLY = CALCULATE([Fees Billed YTD],SAMEPERIODLASTYEAR(Table_BasicCalendarUS[DateKey]))
The error message suggests that there is a bi-directional relationship at the heart of the problem, but
in my date table, the DateKey column has a one-to-many, single cross-filter relationship to the DateBilled colum in the FactTable.
Any suggestions?
Solved! Go to Solution.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
114 | |
97 | |
86 | |
70 | |
62 |
User | Count |
---|---|
151 | |
120 | |
103 | |
87 | |
68 |