Forum Discussion
Userelationship returns wrong results
- 8 years ago
Hi riic0,
You need to have two measures one for open incidents and another for closed incidents in terms of relationships you need to have one of two options:
1) Linked the table by one active relationship and another inactive
2) Linked both table by inactive relationship
In option 1) you need to have one measure that make the normal calculation based on date and another one with the user relationship
In option2) both measure should be calculated based on userrelationship
The formulas should be something like this:
Close Cases = CALCULATE(COUNT(Table1[S]), USERELATIONSHIP('Calendar'[Date],Table1[End date]))In the images below you have the image that show equal versions with and withou active relationship.
As you can sse in the second image when I make the inactive connection the measure having the userrelationship gives correct results the one for active relationships returns 6 for all columns:
Rawa Data:
Option 1) active relationship on open dates:
Option 2) inactive relationship
My measure are simply ones but you can add the filters and all the other complexity and should work.
Regards,
MFelix
Hi Abduvali,
I want to count the closed and opened incidents for each month and show it in one graph so I can compare them.
If I use an column chart for example, I will put the month from the the date table on the Axis. That way it shows the results for each month. If I use the date from the incidents table then I have to choose between the opening date and the closing date. Which both returns wrong results, because for example when I use the Open date it counts the closed incidents on the date from when they were opened.
I hope this makes sense.
Maybe what i'm trying to do is wrong.
I got your point and what you are trying to achieve but just for my own reference, please evaluate the following scenario:
- You had 100 opened incidents in October (Open date Column)
- 90 of those were Closed in October and 10 in November (Close Date column)
- So if you drop those as values in a column chart and look at October it will display 100 open and 90 closed
- and the other 10 tickets will show up in November under Closed tickets
So I'm just trying to understand what will change if you use Date table???
- What do you expect to see from above example using Dates table???
Regards
Abduvali
- riic08 years agoRegular Visitor
Hi Abduvali,
Like I dicussed with MFelix, I need to put the month from the the Date table in order to get the results I want.
For a column chart I need to put the date on the X-axis. The dates from whe an incident is opened and closed are different, so I cant use those.
Maybe i'm not understanding you correctly.
Regards,
riic0