PowerBI Workspace cannot access Azure Synapse SQL Serverless Views - powerbi

I am connecting to a SQL Serverless endpoint located in my Azure Synapse Account for my PowerBI Datasets. I am reading a SQL view that is composed of some parquet files in my data lake.
I am able to connect to the data fine when using PowerBI Desktop since it is using my Active Directory account. But now that I have the report published to a PowerBI Workspace online for other users in my organization I want to have it refresh the dataset daily without having to publish it myself.
Using the online refresh settings I am able to connect to SQL just fine using basic authentication (username/password) but it looks like when PowerBI renders the view it is also checking the credentials for the underlying datalake data which it does not have access to:
Microsoft SQL: Cannot find the CREDENTIAL 'https://mydatalake.dfs.core.windows.net/parquet/**', because it does not exist or you do not have permission. Could not use view or function 'dbo.MyView' because of binding errors.
What is the best way for me to give my PowerBI Workspace permissions to read this view (along with underlying datalake files)?
I'm also puzzled that in PowerBI Workspace I had options to schedule this data set but after a few failed attempts it now states:
You can't schedule refresh for this dataset because the following data sources currently don't support refresh:
And there is nothing after the ":" so now it appears I cannot attempt to connect anymore.
I have the PowerBI Workspace set as a linked service but that does not seem to help since I believe that is only for Synapse to use to connect to the workspace and not the other way.
I was toying with the idea of having Synapse copy the view data to a SQL database outside of Synapse so it can be shared more easily - but my preference would be to avoid this extra layer.

Related

JIRA PowerBI Service data refresh not working

In my PowerBI desktop, I created a Jira dashboard report, and it works perfectly. On the Power BI desktop report, I can view all of my requested data.
Now, when I publish the report https://app.powerbi.com/ the report gets published successfully, however, when I am trying to schedule the refresh, I keep getting below error.
Failed to update data source credentials: The credentials provided for the Web source are invalid. (Source at https://jira.tools.com/.)
When I try to connect straight to my Jira, I know my credentials are accurate and working properly, and the same is true in Powerbi Desktop.
What could be the reason?
Your Jira server might be inside the firewall/inside a private network.
So, the first thing I suggest to try is setting up a Power BI Gateway. Then configure your Power BI Service refresh via that Gateway.
Useful links:
https://learn.microsoft.com/en-us/data-integration/gateway/service-gateway-install
https://learn.microsoft.com/en-us/power-bi/connect-data/service-gateway-data-sources
You'll want to do that on a Server inside your firewall & ensure Proxy settings are correctly setup - to access Internet.
If that doesn't do it - it's probably a more subtle cause (anywhere from the network configuration to how Active Directory is tied to Jira). Let us know, we'll take it from there.

Power BI switching between datasources

I am new to using Power BI gateways. I have created a dashboard using Power BI Desktop connecting to the Test server. Now I have been asked to switch to Production but they wont give me access to the Production. Instead they have setup a data source using Manage Gateways in PBI Service and they are asking me to consume it in my reports. I am so confused if it is actually possible to switch my reports to Production without having access to it. I believe we cannot link PBI Desktop with the DS setup in the Gateway connections directly.
I tried parameterizing database connection so that they can switch to Live and publish it. But they raised a question if they change the password one day and there are many reports published, will they have to go through each of these reports and update with the new password.
Can anyone please provide me a solution for this?
I didn't try this approach, but you can try and check this works for you or not.
In your local Power BI file, In Data Source Settings provide the Production server name.
Give a dummy User ID and Password
Now publish the report to the Power BI Service
Ask your admin now to add appropriate Gateway to the data source. While adding gateway to the data source, the admin should asked for database Credentials and after providing information, it should work.
As I said this is not tested here, I can just hope for the best :)

How to call the Power BI Activity Log API

I would like to call the Power BI Activity Log API with data factory each day to download the activity events into a blob store. I thought I'd use a Copy data activity with an HTTP dataset as source to call the REST API. How do I authenticate in the HTTP dataset's linked service? Do I need to register an Azure AD application with Power BI admin rights and refer to it in some way in the linked service?
Maybe you can have a look at Service Principals, it can help you to easily authenticate and access Power BI admin read-only APIs (ActivityEvents API included) without tying you to a particular user account. Its in preview feature as of today, but should be soon out of preview.
Also, for automating the fetching of logs using Azure Data Factory and ingesting it in Azure Blob, you may have a look at this great article which explains in detail, all the steps that will be required to create the pipeline. Should be helpful!

Error when trying to configure Power BI Data Gatwewy

Just installed Power BI Data Gateway on one of the companies servers.
The processes was smooth and very easy, I have assigned a name to the Data Gateway.
As it is linked to my email (I think this is going to be another problem when other employees trying to publish their reports), when I tried to configure datasource in my Gateway I get this error !
Unable to connect: We encountered an error while trying to connect to . Details: ""
Activity ID: 951737c3-eea2-43c3-b5d4-7bb03e247e5b
Request ID: b7c69cff-2be9-f965-2586-14b978802dd7
Cluster URI: https://wabi-australia-southeast-redirect.analysis.windows.net
Status code: 400
Error Code: DMTS_UpdateClusterDatasourceCredentialsErrorCode
Time: Mon Sep 02 2019 10:15:31 GMT+1000 (AUS Eastern Standard Time)
Version: 13.0.10599.151
PBIGateway: The on-premises data gateway's service account failed to impersonate the user.
I am sure that my user ID and password are both correct, not sure why it is not working!!
This one had me stumped for days. Why would the PBI desktop app allow connections, seamlessly on your desktop and yet when you publish a report to the web, bong-bong no authentication, no credentials, nothing! It was very frustrating, and no specific details other than a plethora of connection IDs which mean nothing.
In the end, we found the problem was between how we've set up the Power BI Gateway on-prem, and whether the gateway service account on the gateway had the permissions to access our data sources, both from SQL Server on-prem and an Excel table in Sharepoint.
When setting up your Gateway (not a personal GW, but a server side one), we've created the gateway using the Admin local account. That was our first mistake. We couldn't connect to any of our SQL Server databases, from Sharepoint. So we've re-installed it using an Admin O365 AD account. Our SQL Server access was ok, but anything in Sharepoint wouldn't work - even though the same account was used to put Excel files and CSV files into Sharepoint.
We then noticed that the gateway was defaulted to a service account under the NT Authority group. Again, another local account. Changed that to another O365 account, but again - nothing would allow us to connect to the Excel sharepoint file! How hard can this be, when the Excel file connected fine inside PowerBI desktop! It was very frustrating.
So we've re-installed the on-prem gateway again, but this time used one AD account for it's sign on, and another system AD account for it's service account. We also publish the PBI report to the cloud, but the dataset would be failing to connect to the Excel file in Sharepoint. WHY!!!???
It came to that User tab and putting our on-prem gateway service account in the User list of the connector to the Sharepoint file.
VOILA!! It worked.
In summary:
Create your PBI reports in desktop and point everything you need to what ever you need in the Get Data wizards
If you're referring to an Excel file, DO NOT point to a local / network Excel file. You're wasting your time.
Put the Excel/CSV or whatever in sharepoint in a Documents folder somewhere
Click Manage Permissions on the file and add the On-Prem service gateway to the list
Next, open the Excel file on the web
And go ahead and open it in your local desktop Excel as well
Go to FILE --> INFO
Click Copy Location to store the location of the file in the clipboard. Save this string in notepad
Close Excel on-prem
Close Excel online
Go to your PBI report and edit the M-Code via the Advanced Editor of your data source
Replace the C drive location of your Excel filepath with the one copied into your notepad
Now your query is pointing to the Excel file in sharepoint.
Publish your report
Go to app.powerbi.com and go to your report's dataset
Click the three dots and go to Settings
Go to Gateway Cluster and lick Manage Gateway link
Open up your gateway cluster and go to your Excel data connector
Select it and click the Users tab
Add your on-prem gateway service account again to this list
Save
Refresh your dataset
Voila! No more errors.
I hope this lengthy answer has been enough for your to realise [1] microsoft write great software, but crappy user-experience with it and [2] you need to pass on the credentials of the gateway to any datasource that uses it, in reference to any datasource that require a gateway between on-prem and cloud reports.
We have same problem in powerbi gateway. Turns out the database password is expired. After reset password. Problem solved.

Power BI Error: Alternate credentials for Windows authentication is not supported in DirectQuery mode

I have a problem when i want to use DirectQuery. I have a DomainController with installed SQL Server. I have installed Data Gateway and must modify the Service Account to Local System to be able to finish setup. i have setup the Data Gateway successfully in Enterprise Mode. In PowerBi.com everything looks fine and can see the Gateway and no errors.
When i now create a new File with a SQL connection and Mode "Import" and publish it to PowerBi.com, then it works fine and when i schedule a refresh, this works fine, too.
But i want to use DirectQuery on a Database table for example. For this scenario i have created a new Power BI File and selected the same database which i already created as DataSet in PowerBI.com under my Gateway. Then i load the data in the file and while trying to load it i am always receiving the following error message:
Create Connections
Alternate credentials for Windows authentication is
not supported in DirectQuery mode. Use your current windows
credentials, supply a database credential or switch to import mode.
In PowerBI.com under Gateways and Data source i have used Windows Authentication and used the Administrator account which has also permission on the Database. I dont know what this message means and i should change. Can someone help me?
it seems that your have a credential problem, I suggest you to go to File->Options and settings->Data source settings, then edit your data source [Edit Permissions...] and specify a valid Windows credential or database credential. After that, click "Refresh" button in the PBIX file.
Hope that helps!
If you cannot open the PBIX file, restart Power BI designer with an empty one and then go to the File, Options as explained above. You will find out that an "alternate" credential has been stored for your data source. Use your current credentials instead. Now, try to open the original PBIX file and it you will see that now Direct Query mode works.