Reply
TJCappy
Frequent Visitor

Sum with multiple filters for different columns in the same table

Ihave two tables,
1 is employeedirectory and has thr following columns:
employeename
EmployeeID
department
Title


2 is XFX Genesys Agent queue and has the following columns:
Interaction type,
Queuename,
Accepted,
Agent name,
Handle time,
AgentID.


the two tables are connected by columns EmployeeID and AgentID
I need to create a measure that will give me the number of calls each agent has accepted "inbound" from each of the queues 

the  Accepted column is a number that represents the total number of calls accepted within the period of an hour.

I have tried the following but nothing seems to give me the result I need 


a)
Calls Accepted by Agent = CALCULATE( SUMX( FILTER( 'xFX Genesys Agent Queue', 'XFX Genesys Agent Queue'[Interaction type] = "Inbound" && 'XFX Genesys Agent Queue'[Accepted] > 0 ), 'XFX Genesys Agent Queue'[Accepted] ) )

b)
Calls Accepted by Agent = CALCULATE( COUNTROWS('XFX Genesys Agent Queue'), FILTER( X'FX Genesys Agent Queue', 'FX Genesys Agent Queue'[Interaction type] = "Inbound" && 'XFX Genesys Agent Queue'[Accepted] > 0 ) )

I have also tried various combinations of summarize and summarizecolumn 

 

All to no avail

 

can someone please help me out.  Thanks

 

1 ACCEPTED SOLUTION
v-yohua-msft
Community Support
Community Support

Hi, @TJCappy 

Based on your information, I created two sample tables:

vyohuamsft_0-1715325504277.png

 

Then create a new measure and try the following dax expression:

 

Calls Accepted by Agent = 
SUMX(
    FILTER(
        'XFX Genesys Agent Queue', 
        'XFX Genesys Agent Queue'[InteractionType] = "Inbound" && 
        'XFX Genesys Agent Queue'[Accepted] > 0
    ), 
    'XFX Genesys Agent Queue'[Accepted]
)

 

vyohuamsft_1-1715325788984.png

 

You can create another slicer and put the Queuename in it to filter the number of times different Queuenames are used.

Here is my preview:

vyohuamsft_2-1715325813102.png

 

How to Get Your Question Answered Quickly 

Best Regards

Yongkang Hua

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

View solution in original post

1 REPLY 1
v-yohua-msft
Community Support
Community Support

Hi, @TJCappy 

Based on your information, I created two sample tables:

vyohuamsft_0-1715325504277.png

 

Then create a new measure and try the following dax expression:

 

Calls Accepted by Agent = 
SUMX(
    FILTER(
        'XFX Genesys Agent Queue', 
        'XFX Genesys Agent Queue'[InteractionType] = "Inbound" && 
        'XFX Genesys Agent Queue'[Accepted] > 0
    ), 
    'XFX Genesys Agent Queue'[Accepted]
)

 

vyohuamsft_1-1715325788984.png

 

You can create another slicer and put the Queuename in it to filter the number of times different Queuenames are used.

Here is my preview:

vyohuamsft_2-1715325813102.png

 

How to Get Your Question Answered Quickly 

Best Regards

Yongkang Hua

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

avatar user

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

Feb2025 NL Carousel

Fabric Community Update - February 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors (Last Month)
Top Kudoed Authors (Last Month)