Allow dataflows to refresh data from a Azure SQL Database read-only replica (using [MultiSubnetFailover=True]) without using an on-premises data gateway
Allow dataflows to refresh data from a Azure SQL Database read-only replica (using [MultiSubnetFailover=True]) without using an on-premises data gateway. Currently this is only possible when using an on-premises data gateway (which is undesirable for Azure SQL DB).
Steps to reproduce:
- Create an Azure SQL Database on the Business Critical tier
- Create a dataflow with the M query code as below, replacing [DatabaseServer] and [DatabaseName] with the details of your Business Critical Azure SQL database. Ensure the connection is not using the on-premises data gateway.
let
Source = Sql.Database("[DatabaseServer]", "[DatabaseName]", [CommandTimeout = #duration(0, 2, 0, 0), Query = "SELECT DATABASEPROPERTYEX(DB_NAME(), 'Updateability') AS Updateability", MultiSubnetFailover = true]),
#"Transform columns" = Table.TransformColumnTypes(Source, {{"Updateability", type text}}),
#"Replace errors" = Table.ReplaceErrorValues(#"Transform columns", {{"Updateability", null}})
in
#"Replace errors"
- Note that the query returns “READ_ONLY” in the PowerQuery preview
- Save and refresh the dataflow
- Connect to the dataflow in PBI Desktop or Excel. Note that the dataflow now returns “READ_WRITE”, indicating that it has refreshed using the primary instance and not the read only replica as would be expected
- Edit the dataflow and change the data source so that it connects through an on-premises data gateway
- Save and refresh the dataflow
- Connect to the dataflow in PBI Desktop or Excel. Note that the query now returns “READ_ONLY”, indicating that it is using the read only replica as it should do.
I have been advised by Microsoft this is by design behaviour for dataflows as they can write data as well as read it. The gateway operations use different settings and thus don't reflect the same behaviour as the Power BI Service. Hence, when you use gateway it gives you read-only replicas. I have been asked to raise an idea on the ideas forum where the idea may be taken into consideration for the future if it receives sufficient votes.
1 Comment
- fbcideas_migusrNew MemberStatus added:New
Recent ideas
Consistent Locale Handling Across Power BI, Fabric, PowerPoint, and Subscriptions
Microsoft Fabric and Power BI should provide consistent locale handling across all user experiences. Today, locales such as German (Switzerland) are correctly respected in Power BI Desktop and the Po...Le_M52 minutes agoRegular VisitorNew11Views1like0CommentsIn Data Pipelines, Schedules should not be part of the definition
The request is to ensure Schedules are not included in the definition of a Data Pipeline for purposes of Deployment Pipelines. Today, when we deploy content across environments, the item frequent...schneiw1 hour agoAdvocate IVUnder Review812Views25likes3CommentsPipeline activity Refresh SQL Endpoint (preview) does not accept dynamic content
I am testing out the new Pipeline activity for Refresh SQL Endpoint, currently in preview. Sure, I get it that this is in preview, but it should at least have basic minimum functionality. It do...ToddChitt1 hour agoSuper UserNew586Views8likes6CommentsPower BI Admin & Governance Center – Centralized Activity and Usage Analytics
Subject: Feature Proposal: Advanced Power BI Admin & Governance Center – Centralized Activity, Access, Sharing, Licensing and Usage Analytics Dear Microsoft Power BI Team, I would like to propose a...Dr7awb6 hours agoNew MemberNew4Views0likes0CommentsFeature Proposal: Expandable/Collapsible Page Sections for Reports on Same Semantic Model
Subject: Feature Proposal: Expandable/Collapsible Page Sections for Reports Using the Same Semantic Model Dear Microsoft Power BI Team, I would like to propose an enhancement to the Power BI report...Dr7awb6 hours agoNew MemberNew3Views0likes0Comments