Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
sandy8910
Frequent Visitor

Counting the specific result from another measure

Hi Everyone,

 

I am very new to Power BI. I have the following:

 

1. Employee Full Name (From Emp table)

2. Employee Earned amount (From Emp table)

3. Employee Task completed  (From Emp table)

4. Total Earned amount (Measure:= Sum(Employee Earned amount))

5. Total Task completed (Measure:= Sum(Employee Task completed))

6. Earned amount per task (Measure: = Divide(Total Earned amount,Total Task Completed))

 

Now I need a measure that should give me the count of Employees who earned more than $2 per WOID.

 

Issure is when I try to use CountX or Calculated Function, It does not let me refernce the original table (I need to refer to orignial table because I want a count of Full names of Employees from table and $2 value from measure table) 

Can anyone help?

 

 

 

1 ACCEPTED SOLUTION
BA_Pete
Super User
Super User

Hi @sandy8910 ,

 

Try something like this:

_empsEarnedOver2USD =
CALCULATE(
  COUNT(empTable[Employee Full Name]),
  FILTER(
    empTable,
    [Total Earned Amount] > 2,
  )
)

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




View solution in original post

3 REPLIES 3
BA_Pete
Super User
Super User

Hi @sandy8910 ,

 

Try something like this:

_empsEarnedOver2USD =
CALCULATE(
  COUNT(empTable[Employee Full Name]),
  FILTER(
    empTable,
    [Total Earned Amount] > 2,
  )
)

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




Thanks BA_Pete for quick response,

 

Below funcation from parry2k in another thread has helped me get the answer

 

COUNTX ( VALUES ( Table[Date column] ), IF ( [Your Measure] < 3, 1 ) )

 

@sandy8910 ,

 

No problem, glad it's sorted.

 

Please accept your answer as the solution if you feel that it would help others with the same issue.

This helps others find the answer to their issues quicker.

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.