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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
trina46844
Regular Visitor

Calculate Percentage of Employed individuals on contract vs Authorized by Company from 2 Tables

Requesting assistance calculating the number of indivduals who are actually employed vs the number who are authorized for employment for each company.  Table 1 is those actually employed.  Table 2 are positions that are authorized.  Results is what I'm looking to achieve.  Please help.  Thanks.  I appreciate your assistance.

 

Test.JPG

2 ACCEPTED SOLUTIONS
jdbuchanan71
Super User
Super User

@trina46844 Do you have a company table that sits over 'Table 1' and 'Table 2' and joins them together?

If not you can create one by creating a new table with a DAX formula like this.

Companies =
DISTINCT (
    UNION (
        DISTINCT ( 'Table 1'[Fill Company] ),
        DISTINCT ( 'Table 2'[Fill Company] )
    )
)

You would join that into your data tables then your result would be something like 

RESULT =
DIVIDE ( COUNTROWS ( 'Table 1' ), SUM ( 'Table 2'[Auth Count] ) )

View solution in original post

Ashish_Mathur
Super User
Super User

Hi,

Share the source data from where those 2 tables have been built.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

3 REPLIES 3
Ashish_Mathur
Super User
Super User

Hi,

Share the source data from where those 2 tables have been built.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
jdbuchanan71
Super User
Super User

@trina46844 Do you have a company table that sits over 'Table 1' and 'Table 2' and joins them together?

If not you can create one by creating a new table with a DAX formula like this.

Companies =
DISTINCT (
    UNION (
        DISTINCT ( 'Table 1'[Fill Company] ),
        DISTINCT ( 'Table 2'[Fill Company] )
    )
)

You would join that into your data tables then your result would be something like 

RESULT =
DIVIDE ( COUNTROWS ( 'Table 1' ), SUM ( 'Table 2'[Auth Count] ) )

Thanks for your help.  This worked.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.