Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello Expert,
I want to show 2 bar of commoditry:
- Fisrt Bar: shows commodity that have amount when ( coontry of Import = country of Origin).
- Second Bar: shows commodity that have amount when ( coontry of Import dose Not equal to country of Origin).
Thank You.
| Country of Origin | Country of Import | Commodity | Point of Entry | Amount |
| China | China | Multiple Loudspeakers | Sarfayt Land Border | 34 |
| China | UAE | Ball Bearings | SOHAR (SEA PORT) | 3445 |
| UAE | UAE | Multiple Loudspeakers | Al Wajajah Land Border | 5676 |
| China | China | Multiple Loudspeakers | Customs HQ | 6768 |
| China | UAE | Skulcaps (Taqias) | HAFEET (BORDER POST) | 342 |
| UAE | KSA | Skulcaps (Taqias) | Sarfayt Land Border | 132 |
| China | UAE | Dress Patterns | KHATMAT MILAHA (BORDER POST) | 323 |
| Turkey | UAE | Skulcaps (Taqias) | Al Darah | 234 |
| China | Russia | Skulcaps (Taqias) | Al Wajajah Land Border | 4545 |
| China | India | Dress Patterns | SUWEIQ (SEA PORT) | 76 |
| Turkey | Turkey | Ball Bearings | AL DUQM (SEA PORT) | 545 |
| KSA | Oman | Dress Patterns | SARFAIT (BORDER POST) | 450 |
| KSA | KSA | Multiple Loudspeakers | CENTRAL POST OFFICE | 164 |
| KSA | Japan | Dress Patterns | Salalah International Airport Passenger | 247 |
| KSA | KSA | Multiple Loudspeakers | DIBA PORT (BORDER POST) | 384 |
| KSA | India | Dress Patterns | Al Darah | 109 |
| USA | USA | Ball Bearings | DIRECTORATE GENERA | 263 |
| USA | Brazil | Dress Patterns | Sarfayt Land Border | 305 |
| USA | Canada | Fuel oils For ships | ARKAN SOHAR LOGISTICS LLC NORTH | 486 |
| USA | USA | Ball Bearings | HAFEET (BORDER POST) | 417 |
| USA | USA | Ball Bearings | ARKAN SOHAR LOGISTICS LLC NORTH | 433 |
| USA | Egypt | Fuel oils For ships | DIBA PORT (BORDER POST) | 334 |
| USA | Iraq | Fuel oils For ships | Sarfayt Land Border | 209 |
Solved! Go to Solution.
Hi,
Please check the below measures and the attached pbix file whether it suits your requirement.
Amount orging import same: =
VAR _newtable =
FILTER (
ADDCOLUMNS (
Data,
"@origin", CALCULATE ( MAX ( Data[Country of Origin] ) ),
"@import", CALCULATE ( MAX ( Data[Country of Import] ) )
),
[@origin] = [@import]
)
RETURN
SUMX ( _newtable, Data[Amount] )
Amount orging import diff: =
VAR _newtable =
FILTER (
ADDCOLUMNS (
Data,
"@origin", CALCULATE ( MAX ( Data[Country of Origin] ) ),
"@import", CALCULATE ( MAX ( Data[Country of Import] ) )
),
[@origin] <> [@import]
)
RETURN
SUMX ( _newtable, Data[Amount] )
Hi,
Please check the below measures and the attached pbix file whether it suits your requirement.
Amount orging import same: =
VAR _newtable =
FILTER (
ADDCOLUMNS (
Data,
"@origin", CALCULATE ( MAX ( Data[Country of Origin] ) ),
"@import", CALCULATE ( MAX ( Data[Country of Import] ) )
),
[@origin] = [@import]
)
RETURN
SUMX ( _newtable, Data[Amount] )
Amount orging import diff: =
VAR _newtable =
FILTER (
ADDCOLUMNS (
Data,
"@origin", CALCULATE ( MAX ( Data[Country of Origin] ) ),
"@import", CALCULATE ( MAX ( Data[Country of Import] ) )
),
[@origin] <> [@import]
)
RETURN
SUMX ( _newtable, Data[Amount] )
You are a great.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 6 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 25 | |
| 16 | |
| 8 | |
| 7 | |
| 7 |