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

A new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.

Reply
brlimagu
Frequent Visitor

Filled map issue

I have a column that has a bunch of country codes and I have created a calculated column to "transform" this codes into the country name (see below) doing so I could use Filled map to fill the countries with the data needed. But the tricky situation is that I need to fill Middle East, Eastern Africa and Central Africa and Bing does not fill it. Is there any way to fill those regions? Maybe create a new column? But how to relate the Code with more than one country?

 

In my database I have some IDs that references a country code and I use the Switch function to create the country name column.

 

Is switch function the best way to do that? 

 

Market Name = SWITCH(Folder[ParentID];6939;"CHINA";6940;"Eastern Africa";6941;"Indonesia";6942;"Japan";6943;"Korea";6944;"Sri Lanka";6945;"Malaysia";6946;"New Zealand";6947;"Filipinas";6948;"Thailand";6949;"Turkey";6950;"South Africa";6951;"Australia";6952;"Egypt";6953;"Ghana";6954;"Israel";6955;"India";6956;"Middle East";6957;"Pakistan";6958;"Vietnam";6959;"Kenya";6960;"Central Africa";6585;"Australia" )

 

image.pngimage.png

1 REPLY 1
v-jiascu-msft
Microsoft Employee
Microsoft Employee

Hi @brlimagu,

 

Since you only have country code, creating a new column of country name is essential. Switch function is good. 

 

If you want to group many country into a big region, you can add a conditional column, then add it to the legend.

1. Add a conditional column. It's Zone in my example.

 

Filled map issue.jpg

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

2. Create a measure for the color saturation like this:

ColorValues =
CALCULATE ( SUM ( 'Table1'[Value] ); ALLEXCEPT ( Table1; 'Table1'[Zone] ) )

3. You can see there are three colors and the value of each country of each zone is the same respective. So the color would be the same.

 

Filled map issue2.jpg

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Best Regards!

Dale

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

Helpful resources

Announcements
May Power BI Update Carousel

Power BI Monthly Update - May 2026

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

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.