Forum Discussion
Measure based on 2 tables
- 8 years ago
I think this can be done fairly easily.
Just use "new measure" and use DISTINCTCOUNT('Hires'[ID])/(DISTINCTCOUNT('Hires'[ID])+DISTINCTCOUTN('Employees'[ID])). You may then want to format the measure as "%".
Please try it out and let us know if this works as I have not tested it myself.
- Anonymous8 years ago
Anonymous There are many ways, easiest and cleanest way is using variables and here is a screenshot of the same.
Hiring Rate = VAR EmpCount = CALCULATE(DISTINCTCOUNT(Employees[Country])) VAR HiresCount = CALCULATE(DISTINCTCOUNT(Hires[Country])) RETURN DIVIDE(HiresCount,EmpCount,0)
I think this can be done fairly easily.
Just use "new measure" and use DISTINCTCOUNT('Hires'[ID])/(DISTINCTCOUNT('Hires'[ID])+DISTINCTCOUTN('Employees'[ID])). You may then want to format the measure as "%".
Please try it out and let us know if this works as I have not tested it myself.
Hey,
Can you explain why we are adding ID of hires also in the denominator?
- Anonymous8 years agoNot applicable
Anonymous
Wasn't that your question
"o I want to be able to calculate the hiring rate based on the two tables which would be count of ID in Hires table divided by count of ID's in the employee table. Is there a way that I can create a measure to calculate the hiring rate based on the ID's from the 2 tables? "
- Anonymous8 years agoNot applicable
Anonymous Hey I did not check your output while typing that. I was replying for the other solution.
I'll check this out and let you know!
- Anonymous8 years agoNot applicable
Anonymous if this is accepted solution, could you mark it as one.
- PowerBSer8 years agoFrequent Visitor
My mistake. If Employees is all-inclusive then you should not add it in the denominator.
- Anonymous8 years agoNot applicable