cancel
Showing results for
Did you mean:

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Regular Visitor

## Measure to calculate an average count of rows based on work days value stored in another table

Hello,

I have a table containing workflows submitted along with the day they were made and the ID. It resembles this:

I have another table containing the work days (business days) for each month that looks like this:

I joined the tables on the Year-Month column.

What I would like is a count of IDs for each workflow divided by the amount of W_Days for that month. So in the above examples, Coverage would have a count of 2 divided by 20 work days for April producing an average of 0.10 per workday, and a count of 3 divided by 22 for May producing an avaerage of 0.14 per workday. Is there a measure I can create for this?

1 ACCEPTED SOLUTION
Community Support

Data Model:

Create a table visual by 'Work Day'[Month_Year] and 'Table'[Workflow].

``````Measure =
VAR _COUNT = COUNT('Table'[ID])
VAR _WORKDAY = CALCULATE(SUM('Work Days'[W_Days]))
RETURN
DIVIDE(_COUNT,_WORKDAY)``````

Result is as below.

Best Regards,
Rico Zhou

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

2 REPLIES 2
Community Support

Data Model:

Create a table visual by 'Work Day'[Month_Year] and 'Table'[Workflow].

``````Measure =
VAR _COUNT = COUNT('Table'[ID])
VAR _WORKDAY = CALCULATE(SUM('Work Days'[W_Days]))
RETURN
DIVIDE(_COUNT,_WORKDAY)``````

Result is as below.

Best Regards,
Rico Zhou

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Regular Visitor

Thank you! This worked.

Announcements

#### Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

#### Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

#### The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors