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.
Dear all,
I have two dimesion table(d_date and d_cases) both link to a fact table(f_call)
Now I want to use userelationship to build realtionship between my two dimesion tables. My goal is to use d_date as a slicer to filter the report, and count how many cases completion from cases table. But is gave error: USERELATIONSHIP function can only use the two columns references participating in relationship.
Below is my dax function:
Solved! Go to Solution.
@xiumi_hou so after setting the relationship, did it worked?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
I believe the error is stating that you need either an active or inactive relationship that already has been set. Only then will you be able to use the USERELATIONSHIP function. What you want actually would be to use TREATAS
So in your example, something like this:
Thanks for the reply. When I changed the funtion, it gave below error, could you please help me check it?
Too many arguments were passed to the VALUES function. The maximum argument count for the function is 1.
did you forget to close the parenthesis after VALUES?
@xiumi_hou can you make sure you have relationship between d_cases[closed_date] with d_date[Date]
if you already have relationship between these two tables on other column, you still need to set relationship on closed_date which will be inactive.
There can be only one active relationship, but you can have more than one inactive relationships
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Thanks Parry, it seems I forgot to create a new relationship and then use userelationship function.
@xiumi_hou so after setting the relationship, did it worked?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
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 | |
100 | |
81 | |
70 | |
62 |
User | Count |
---|---|
148 | |
116 | |
104 | |
90 | |
65 |