Forum Discussion
Power BI API doesn't disable Direct Query, but example on reference says it should
- 3 years ago
Hey Anonymous ,
as you have noticed the API does not affect the Caching in DQ mode that helps to pre-populate Dashboard and Reports.
From my knowledge you can use this setting:You will find this setting in the dataset settings, of course this setting is only available for DQ datasets.
Regards,
Tom
Hey Anonymous ,
as you have noticed the API does not affect the Caching in DQ mode that helps to pre-populate Dashboard and Reports.
From my knowledge you can use this setting:
You will find this setting in the dataset settings, of course this setting is only available for DQ datasets.
Regards,
Tom
- Anonymous3 years agoNot applicable
Hi TomMartens Thanks for your response. I'm looking for a way to turn off the "Automatic dashboard tile and metric refresh" setting through the API. The documentation for DirectQueryRefresh (linked in the OP) states that you can do this ... but doing so has always created an HTTP 415 response. Looking through the C# source code (PowerBI-CSharp/DatasetsOperationsExtensions.cs at master · microsoft/PowerBI-CSharp · GitHub) I notice that the API command takes a DirectQueryRefreshSchedule object (serialized from the JSON payload) but that object doesn't take an "enabled" property (PowerBI-CSharp/DirectQueryRefreshSchedule.cs at b5882f53a7f5704fe70cbfb862b829e5bfc46472 · microsoft/PowerBI-CSharp · GitHub)
public DirectQueryRefreshSchedule(frequency, days, times, localTimeZoneId)
This leads me to believe that either the documentation is faulty or that the API program is incomplete or that the behavior of something that intercepts the "enabled" setting isn't fully defined in the documentation (or is faulty).
I'm hoping someone out there can help me track down what exactly is going on and provide a way to modify this setting through automation.