Forum Discussion

whurter5's avatar
whurter5
Regular Visitor
5 years ago

Direct Query - Imported and refreshed but data source not updated

Hi Guys,

I'm currently importing a direct query report into a new workspace using the *.pbix file.

 

After the import, I update my data source parameter to my new table name and refresh the report.

It works fine if I do this on the desktop app but not on the Power BI service.

Refresh now indicates that the report has been refreshed but the new table columns aren't added to my source table in the dataset

Any ideas as to why this might be happening?

 

 

 

 






3 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi whurter5 ,

    How did you create and set the parameter? Where did you apply the parameter? Server name? Database name? Filter rows or something else? Could you please provide the parameter setting page and the codes which parameter applied on? By the way, did you change the parameter value with "new table name" in Power BI Service after imported the pbix file?

    Power BI Desktop Query Parameters Introduction

    In addition, could you please publish the report with new parameter name to Power BI Service? Then check whether the dataset can load the fields from new table...

    Best Regards

    • whurter5's avatar
      whurter5
      Regular Visitor

      Hi Anonymous,

       

      Die initial report was created in the PowerBI desktop app. It's a direct query report that only has three parameters, one for the server name, one for the database name, and one for the table name. 

      The idea was to use this report as the base report for different variations of the same report that I would like to generate via the API and use for our embedded implementation. 

       

      I attempted to clone the report by importing it into a new workspace and updating the source SQL table parameter. The newly generated report is reading the correct table, but the report metadata is not updated. The new tables' columns aren't added as fields on the report.

       

      https://docs.microsoft.com/en-us/power-bi/connect-data/desktop-directquery-about

      According to this link, you can only update the report metadata via the PowerBI desktop app. As I am trying to automate the generation of these reports, this isn't a viable solution for me.

       

      I ended up building a tabular object model in code and attaching it to a clone of the base report

       

      Could you please confirm that it's only possible to update a direct query reports'' metadata via the PowerBI desktop app at this point?