Search code examples
powerbivisualizationpowerbi-desktopazure-maps

Power BI Slicer Issue


I'm working on an Azure Map to visualize client data. Here’s the scenario: I want to display two types of data on the map — the locations of our clients and the locations of our babysitters. These data are in separate tables. The goal of the map is to assist the sales team in matching, i.e., identifying babysitters who are near or in the same region as a client.

I need to display both datasets on the same map and use a slicer to specify the profiles of babysitters since there are several categories. However, when I apply the slicer, it affects both clients and babysitters, but I only want it to filter the babysitters. I tried using a measure field slicer, but it didn’t work due to the level of detail required for displaying babysitters.

enter image description here Above I have added the map, I only want my slicer to apply to the red dots.

Is there another way to apply the slicer to only one specific column or dataset? Any help would be greatly appreciated!


Solution

  • One way is to use UNION() to create a virtual table to combine the two groups in a single table:

    BuyersAndSellers = UNION (
                        SELECTCOLUMNS(Buyers,"Name",[Name],"Age",[Age],"Role","Buyer"),
                        SELECTCOLUMNS(Sellers,"Name",[Name],"Age",[Age],"Role","Seller")
    )
    

    In my example, I only have {Name, Age} and then buyers are in one table and sellers in another. So I added the "Role" column so I could differentiate them. You could do that kind of thing and include the columns you're using for mapping (address or (long, lat)), and color the dots based on "Role" or whatever. Then I think you can join back to the original table(s) and grab the relationship through that.