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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
Syndicate_Admin
Administrator
Administrator

Inputs, Outputs and Differences

Hello everyone

I am making a balance scorecard, with entries and exits of the municipalities, and then the difference between the two.

For this I have a table with three fields: CT ISLAND, RESI ISLAND, Counter. This calculates me between the two communes of Municipalities how many it has. That is, each row is the result of MunicipalityCT to MunicipalityResi or vice versa, and it may be the case that it has different results for the same combination of municipalities:

The fact is that when I try to do the subtraction, the difference for a municipality between the two fields comes out to zero, since it only detects one of them and not both.

NachoAl_5-1724916771869.png

The measurements I use to calculate the entrances and exits are:

IslandsInputs=CALCULATE(

SUM('Consulta1'[num_contratos]);

Query1[ISLAND CT] = SELECTEDVALUE(Query1[ISLAND CT]);

'Consultation1'[CT ISLAND] <> 'Consultation1'[Residence ISLAND]

)

DeparturesIslands=

CALCULATE(

SUM('Consulta1'[num_contratos]);

Query1[RESIDENCE ISLAND] = SELECTEDVALUE(Query1[Residence ISLAND]);

'Consultation1'[Residence ISLAND] <> Consultation1[CT ISLAND]

)

BalanceIslands = [IslandsTickets]-[Island Departures]

NachoAl_4-1724916672739.png

I hope you can help me to see the light. Thank you very much in advance

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Syndicate_Admin ,

 

Maybe you should create table slicer about [ISLAND CT] and [Residence ISLAND]. You can refer to demo like below:

DeparturesIslands = 
CALCULATE(
    SUM('Consulta1'[num_contratos]),
    'Consulta1'[RESIDENCE ISLAND] = SELECTEDVALUE('slicer'[RESIDENCE ISLAND]),
    'Consulta1'[RESIDENCE ISLAND] <> 'Consulta1'[CT ISLAND]
)
IslandsInputs = 
CALCULATE(
    SUM('Consulta1'[num_contratos]),
    'Consulta1'[CT ISLAND] = SELECTEDVALUE('slicer2'[CT ISLAND]),
    'Consulta1'[CT ISLAND] <> 'Consulta1'[RESIDENCE ISLAND]
)

vkongfanfmsft_0-1725002103172.pngvkongfanfmsft_1-1725002135099.png

Best Regards,
Adamk Kong

 

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
Anonymous
Not applicable

Hi @Syndicate_Admin ,

 

Maybe you should create table slicer about [ISLAND CT] and [Residence ISLAND]. You can refer to demo like below:

DeparturesIslands = 
CALCULATE(
    SUM('Consulta1'[num_contratos]),
    'Consulta1'[RESIDENCE ISLAND] = SELECTEDVALUE('slicer'[RESIDENCE ISLAND]),
    'Consulta1'[RESIDENCE ISLAND] <> 'Consulta1'[CT ISLAND]
)
IslandsInputs = 
CALCULATE(
    SUM('Consulta1'[num_contratos]),
    'Consulta1'[CT ISLAND] = SELECTEDVALUE('slicer2'[CT ISLAND]),
    'Consulta1'[CT ISLAND] <> 'Consulta1'[RESIDENCE ISLAND]
)

vkongfanfmsft_0-1725002103172.pngvkongfanfmsft_1-1725002135099.png

Best Regards,
Adamk Kong

 

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

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

Check out the February 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.