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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

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.

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

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

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.

Top Kudoed Authors