cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
hadoka Frequent Visitor
Frequent Visitor

SUM of Count in two different Tables

Hello Team , 

 

I would like to ask for you help, Basically I have a table for IT Insidents , and Table for IT Requests .. 

 

in Each table there is a Column where all ticket numbers are listed, so I use count to know how many Riquests , and how many incidents , 

 

However i want to SUM both , how can i do that, i'm working on a dashboard where i'll show ticket per region , and total tickets handeled by teams etc .. so i need to combine both Requests & Insidents . 

 

Note : the two tables are related to each other by Region Column,.

 

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: SUM of Count in two different Tables

@hadoka it should be straight forward:

 

Total Tickets = 
COUNTROWS( Table_Incident ) + COUNTROWS( Table_Tickets )





Did I answer your question? Mark my post as a solution.

Proud to be a Datanaut! Appreciate your Kudos Smiley Happy
Feel free to email me with any of your BI needs.





3 REPLIES 3
Super User
Super User

Re: SUM of Count in two different Tables

@hadoka it should be straight forward:

 

Total Tickets = 
COUNTROWS( Table_Incident ) + COUNTROWS( Table_Tickets )





Did I answer your question? Mark my post as a solution.

Proud to be a Datanaut! Appreciate your Kudos Smiley Happy
Feel free to email me with any of your BI needs.





Community Support Team
Community Support Team

Re: SUM of Count in two different Tables

Hi @hadoka,

 

Please share some sample data to help us clarify your scenario.

 

In my opinion, I'd like to suggest you use current region value to find out correspond ticket id list, then you can simply get he count of related id request.

Ticket Count =
CALCULATE (
    COUNTROWS ( VALUES ( 'IT Insidents'[TicketID] ) ),
    VALUES ( 'IT Insidents'[Region] )
)


Request Count =
VAR ticketList =
    CALCULATETABLE (
        VALUES ( 'IT Insidents'[TicketID] ),
        VALUES ( 'IT Insidents'[Region] )
    )
RETURN
    CALCULATE (
        COUNTROWS ( 'IT Requests' ),
        FILTER ( ALLSELECTED ( 'IT Requests' ), 'IT Requests'[TicketID] IN ticketList )
    )

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin Sheng
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.



For learning resources/Release notes, please visit: | |
hadoka Frequent Visitor
Frequent Visitor

Re: SUM of Count in two different Tables

Thank you Team .. the first solution worked for me Smiley Happy .. all the best.. 

Helpful resources

Announcements
Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Summit North America

Power Platform Summit North America

Register by September 5 to save $200

PBI Community Highlights

PBI Community Highlights

Check out what's new in the Power BI Community!

MBAS Gallery

Watch Sessions On Demand!

Continue your learning in our online communities.

Top Kudoed Authors
Users Online
Currently online: 93 members 1,790 guests
Please welcome our newest community members: