web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Dynamic Filter on Powe...
Power Apps
Suggested Answer

Dynamic Filter on Power Bi Tile via with Power App

(2) ShareShare
ReportReport
Posted on by 11
 Hello Everybody, 
 
I think i'm in a cul de sac. 
 
I have been trying in last 3 hours to filter my Power Bi Tile on my app using two combobox. 
 
 
The filter works on one of them; however, when cant use the function concat on the other one to filter several values from the field (power bi), it's not working. I have tried without the concat function an just with the URL?filter=Table/Field in ('value1', 'value2') and it's not working. I double checked the table and field used, but i can't find where is the error. 
 
For information, my Power Bi is linked to a Sharepoint with a flow that refresh the Power Bi once the sharepoint is modified. The values i want to filter are text values from the sharepoint and present in the Power Bi. 
 
The code i used to filter the URL on Power App: 
"https://app.powerbi.com/embed?dashboardId=2dda053d-8643-4612-b3be-410b3e200353&tileId=0024a961-6a08-48f0-98ec-c30efd7dde06&config=eyJjbHVzdGVyVXJsIjoiaHR0cHM6Ly9XQUJJLVdFU1QtRVVST1BFLUItUFJJTUFSWS1yZWRpcmVjdC5hbmFseXNpcy53aW5kb3dzLm5ldCIsImVtYmVkRmVhdHVyZXMiOnt9fQ%3d%3d" &
 
If(
    // RULE 1: No filters
    CountRows('Companies-Combobox'.SelectedItems) = 0 &&
    CountRows('BusinessUnit-Combobox'.SelectedItems) = 0,
    "",
 
    // RULE 2: Companies selected (priority)
    CountRows('Companies-Combobox'.SelectedItems) > 0,
    "&$filter=Engagement2/IssuerName in (" &
        Concat(
            'Companies-Combobox'.SelectedItems,
            "'" & Value & "'",
            ","
        ),
 
    // RULE 3: Business Unit only
    "&$filter=Engagement2/BusinessUnit eq '" &
        'BusinessUnit-Combobox'.Selected.Value & "'"
)
 
Name of my table: 
 
 
 
My Field present in the Power Bi Report: 
 
 
When the Report is filtered with AXA: 
 
 
 
 
 
 
My Power App: 
 
 
When filtered with AXA:
 
 
When filtered using the Business Unit combobox: 
 
 
 
 
Thank you for your help !
 
Categories:
I have the same question (0)
  • Suggested answer
    SpongYe Profile Picture
    5,909 Super User 2026 Season 1 on at
    Hi @
     
    The issue is probably in this part of your URL filter:
    "&$filter=Engagement2/IssuerName in (" &
        Concat(
            'Companies-Combobox'.SelectedItems,
            "'" & Value & "'",
            ","
        )
    You open the in ( clause, but you never close it with ).
     
    Try this:
    "https://app.powerbi.com/embed?dashboardId=2dda053d-8643-4612-b3be-410b3e200353&tileId=0024a961-6a08-48f0-98ec-c30efd7dde06&config=eyJjbHVzdGVyVXJsIjoiaHR0cHM6Ly9XQUJJLVdFU1QtRVVST1BFLUItUFJJTUFSWS1yZWRpcmVjdC5hbmFseXNpcy53aW5kb3dzLm5ldCIsImVtYmVkRmVhdHVyZXMiOnt9fQ%3d%3d" &
    
    If(
        CountRows('Companies-Combobox'.SelectedItems) = 0 &&
        CountRows('BusinessUnit-Combobox'.SelectedItems) = 0,
        "",
    
        CountRows('Companies-Combobox'.SelectedItems) > 0,
        "&$filter=Engagement2/IssuerName in (" &
            Concat(
                'Companies-Combobox'.SelectedItems,
                "'" & EncodeUrl(Substitute(Value, "'", "''")) & "'",
                ","
            ) &
        ")",
    
        "&$filter=Engagement2/BusinessUnit eq '" &
            EncodeUrl(Substitute('BusinessUnit-Combobox'.Selected.Value, "'", "''")) &
        "'"
    )
     
    One more point. Your current If() logic gives priority to the company filter. That means if at least one company is selected, the Business Unit filter will not be applied. If you want both comboboxes to filter the Power BI tile at the same time, you need to combine the conditions with and instead of choosing only one branch of the If().

     

    If you have any questions or feedback, please let me know. Have a great day! 😊

    -----------------------
    SpongYe Power Platform Enthusiast [LinkedIn] | [Youtube| [My blog]

     

    I love to share my knowledge and learn from others. If you find my posts helpful, please give them a thumbs up 👍 or mark them as a solution ✔️. You can also check out my blog [@SpongYe] for some cool solutions and insights. Feel free to connect with me on any of the platforms above. Cheers! 🍻

  • AD-28051443-0 Profile Picture
    11 on at
    Hello SpongYe, 
     
    Thank you very much for your help. 
     
    Unfortunately, the code you proposed doesn't update the filter on the graphic (see picture below). 
     
     
    The same filter on the report: 
     
     
     
     
     
     
    The code i used: 
     
    "https://app.powerbi.com/embed?dashboardId=2dda053d-8643-4612-b3be-410b3e200353&tileId=0024a961-6a08-48f0-98ec-c30efd7dde06&config=eyJjbHVzdGVyVXJsIjoiaHR0cHM6Ly9XQUJJLVdFU1QtRVVST1BFLUItUFJJTUFSWS1yZWRpcmVjdC5hbmFseXNpcy53aW5kb3dzLm5ldCIsImVtYmVkRmVhdHVyZXMiOnt9fQ%3d%3d" &
     
    If(
        CountRows('Companies-Combobox'.SelectedItems) = 0 &&
        CountRows('BusinessUnit-Combobox'.SelectedItems) = 0,
        "",
     
        CountRows('Companies-Combobox'.SelectedItems) > 0,
        "&$filter=Engagement2/IssuerName in (" &
            Concat(
                'Companies-Combobox'.SelectedItems,
                "'" & EncodeUrl(Substitute(Value, "'", "''")) & "'",
                ","
            ) &
        ")",
     
        "&$filter=Engagement2/BusinessUnit eq '" &
            EncodeUrl(Substitute('BusinessUnit-Combobox'.Selected.Value, "'", "''")) &
        "'"
    )
     
    Regarding the priority, i do want to prioritize the filter on the company combobox as it is more granular than the business unit. 
     
    Let me know if you have another idea or need more information on my side. Could you confirm that we can use several values from the same field to filter a power bi tile ? 
     
     
    Thank you !
     
  • AD-28051443-0 Profile Picture
    11 on at
    Other example, when i force code to display only two values [AXA, Arxada] it still doesn't work (see picture 1) but on my report it does work (see picture 2)
     
    picture 1:
     
     
    Picture 2: 
     
     
    Thank you for your help !
  • AD-28051443-0 Profile Picture
    11 on at
    Hello, 
     
    I'm still stuck if anyone has an idea. 
     
    Thank you 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 424

#2
WarrenBelz Profile Picture

WarrenBelz 355 Most Valuable Professional

#3
11manish Profile Picture

11manish 290

Last 30 days Overall leaderboard