Forum Discussion

pawanbdiger's avatar
pawanbdiger
New Member
1 year ago
Solved

Need help with dynamic query generation and execution in PowerBI

Hello Experts,

I am seeking help in generating dynamic query and automatic execution of the same in Power BI. Below is the scenario I want to achieve 

1. User has slicer which is having names of columns from multiple tables which can have joins among them

2. User selects column names from multiple tables using this slicer

3. Using the selected column names, a dynamic query is generated e.g (select customerID, customerName, OrderId, OrderType, OrderAmt from Customer left Join Order on Customer.CustomerID = Order.CustomerID where CustomerID = 'XXXXXXXX')

4. Then this query is automatically executed in the background and the resultant data is loaded into a dataset

5. The resultant dataset is binded to a table visual with all columns selected

 

I tried using Dax measure to generate dynamic querystring involving one table, however I am not able to

a. find options to execute this query automatically and bind it to dataset

b. generate dynamic query containing selected columns with join condition

 

Thank You

 

  • No need for a slicer. Enable "Personalize Visuals"  and teach your report users on how to do that.

4 Replies

  • No need for a slicer. Enable "Personalize Visuals"  and teach your report users on how to do that.

  • v-achippa's avatar
    v-achippa
    Community Support

    Hi pawanbdiger,

     

    Thank you for reaching out to Microsoft Fabric Community.

     

    Thank you lbendlin for the prompt response.

     

    As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided by the super user resolved your issue? or let us know if you need any further assistance.
    If our super user response resolved your issue, please mark it as "Accept as solution" and click "Yes" if you found it helpful.

     

    Thanks and regards,

    Anjan Kumar Chippa

    • v-achippa's avatar
      v-achippa
      Community Support

      Hi @pawanbdiger,

       

      We wanted to kindly follow up to check if the solution provided by the super user resolved your issue.
      If our super user response resolved your issue, please mark it as "Accept as solution" and click "Yes" if you found it helpful.

       

      Thanks and regards,

      Anjan Kumar Chippa

      • v-achippa's avatar
        v-achippa
        Community Support

        Hi @pawanbdiger,

         

        As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided by the super user resolved your issue.
        If our super user response resolved your issue, please mark it as "Accept as solution" and click "Yes" if you found it helpful.

         

        Thanks and regards,

        Anjan Kumar Chippa