data protection
331 TopicsLoading data from password encrypted Excel file
Hello everyone, I have an Excel file that is password protected and I'd like to extract data from it in PowerQuery. Is it possible to do it with the Excel Connector ? From my research it seems to be impossible, but all the answers are really old, so I'm asking again just to be sure. Also wouldn't it be possible with a bit of Python in PowerBI ?Solved113Views0likes1CommentPower BI semantic model refresh fails in Service, but Gen1 dataflow and Desktop refresh successfully
Hi everyone, my semantic model refresh fails in Power BI Service with this error: DataFormat.Error: The input couldn't be recognized as a valid Excel document. Microsoft.Data.Mashup.ErrorCode = 10311. The exception was raised by the IDbCommand interface. However: The Gen1 dataflow refreshes successfully. The model also refreshes successfully in Power BI Desktop. I’ve reviewed the Power Query queries and couldn’t find any problems. The failure appears to happen only when refreshing the semantic model in Power BI Service. What could cause this difference, and how can I identify the specific query or source triggering the error? Error details: Cluster: WABI-SOUTH-EAST-ASIA-redirect.analysis.windows.net Activity ID: 76273612-20ed-4ca2-988e-4f593db29fa5 Request ID: 42e32479-4c91-40cf-b83c-e1ebd9591dc4 Time: 2026-09-15 20:18:51 UTC Any help would be appreciated.Solved512Views2likes14CommentsWeb.Contents failed to get contents from 'https://ausreman.tidywork.com/api/materials' (400)
I have tried a number of scenarios for posting data, but I have come up with nothing. I am trying to write a power query that posts data to a REST API (https://ausreman.tidywork.com/api/materials), it posts data for materials. The current query I have is: = Json.Document(Web.Contents("https://ausreman.tidywork.com/api/materials",[Headers= [#"Authorization"="Basic ZZZZZZZZZZZZZZZZZ",#"Content-Type"="application/json"], Content=Json.FromValue({[projectId="65b6d1fe-ec2e-47c3-9c92-2aad8fdd1d26",userId="67220adb-d5cb-4667-a3ce-ebe3d6248334",materialDateUtc="2015-09-14T07:11:00",materialDate="2015-09-14T17:11:00",materialId="00000000-0000-0000-0000-000000000000",materialLocationId="1aeb9552-a3e9-4804-a7b2-641b290dac8d",materialItemCode="1H3338",materialItemId="f9be8264-81f0-4ae2-a12b-569b3e05d034",costCurrencyId="17709522-6b2e-4b01-9cdf-bb7eb0a43c52",chargeCurrencyId="17709522-6b2e-4b01-9cdf-bb7eb0a43c52",taskId="b2ffc2cf-326a-fc91-eb40-c4ddb4147a35",state="Approved",usageQuantity=1,quantity=1,cost=0.21,charge=0.25]})]), 1252) The only thoughts I had was that it had something along the lines of the size of the data being post. Please help me remove this frustration.921Views0likes4CommentsBest Practice for Calling a REST API with Username/Password Authentication Without Storing Credentia
Hi everyone, I'm currently building a Power BI report for a customer that needs to retrieve data from a REST API. The API provider has created a dedicated user account for me (username + password). My current approach is to use a Power Query function to authenticate against the API, retrieve a bearer token, and then use that token to request the actual data. Technically, this works without any issues. The problem is that the username and password have to be hardcoded in the Power Query function, which obviously isn't a secure solution. To make my question easier to understand, I recreated the entire process using the public DummyJSON API. The documentation can be found here: https://dummyjson.com/ First, I use a custom Power Query function (fnGetAccessToken) to obtain a bearer token. The authentication endpoint is documented here: https://dummyjson.com/docs/auth As you can see, the username and password are embedded directly in the source code (these are only demo credentials provided by the sample API, not production credentials): () => let // Get Bearer Token via username & password... TokenRequest = Web.Contents( "https://dummyjson.com/auth/login", [ Headers = [ #"Content-Type" = "application/json" ], Content = Json.FromValue([ username ="emilys", password = "emilyspass" // password exposed in source code 😞 ]) ] ), accessToken = Json.Document(TokenRequest)[accessToken] in accessToken I then use the generated bearer token to retrieve the actual data (in this example, the products endpoint, documented here: https://dummyjson.com/auth/product😞 let // Get access token via function... accessToken = fnGetAccessToken(), // Call REST API Source = Web.Contents( "https://dummyjson.com/auth/product?limit=0", [ Headers = [ Authorization = "Bearer " & accessToken ] ] ), Data = Json.Document(Source), products = Data[products], #"Converted to Table" = Table.FromList(products, Splitter.SplitByNothing(), null, null, ExtraValues.Error), #"Expanded Column1" = Table.ExpandRecordColumn(#"Converted to Table", "Column1", {"id", "title", "description", "category", "price", "discountPercentage", "rating", "stock", "tags", "brand", "sku", "weight", "dimensions", "warrantyInformation", "shippingInformation", "availabilityStatus", "reviews", "returnPolicy", "minimumOrderQuantity", "meta", "images", "thumbnail"}, {"id", "title", "description", "category", "price", "discountPercentage", "rating", "stock", "tags", "brand", "sku", "weight", "dimensions", "warrantyInformation", "shippingInformation", "availabilityStatus", "reviews", "returnPolicy", "minimumOrderQuantity", "meta", "images", "thumbnail"}) in #"Expanded Column1" For both endpoints (https://dummyjson.com/auth/login and https://dummyjson.com/auth/product), the authentication method configured in Data Source Settings is Anonymous. My question is: What is considered the recommended or best-practice approach for this scenario? I need to keep the authentication flow (username/password → bearer token → API request), but I don't want to store sensitive credentials directly in the Power Query source code. I've been wondering whether the solution involves an Azure App Registration together with Azure Key Vault. However, I'm not sure whether that approach is even appropriate for a third-party API, or how such an API would fit into an Azure App Registration. Is there a more common or simpler approach that I'm overlooking? I'd appreciate any guidance or recommendations. Thanks in advance!Solved532Views0likes2CommentsPower BI: Model is not working as expected
Problem: I am building a Power BI semantic model (Fabric) to report Actual vs Budget across a hierarchy Level 1 → Level 2 → Level 3 → Level 4. Actuals exist at Level 4 (Level 1–4 columns) Budget exists only at Level 3 (Level 1–3 columns) Expected: In a single Matrix visual, I should be able to place the hierarchy (Level 1–4) on rows and show: Actual Amount (USD) Budget 2026 Both measures should filter correctly when I select any level (Level1/Level2/Level3/Level4) via slicers or drilldown. Actual result: After normalizing into dimension tables and fact tables, the model still behaves incorrectly: Budget does not filter correctly when Level 4 is on rows (Budget repeats or behaves like “not filtered” in some contexts). Actual amounts also filter inconsistently in some scenarios (some hierarchy combinations disappear when measures are added). I need help identifying the exact modeling issue and the best production approach when Budget exists only up to Level 3 but reporting needs to work down to Level 4. What I’m looking for in the answer Exact explanation of why filter context is not reaching FactBudget at Level 4 Recommended final schema (star/snowflake/bridge) with relationship directions and cardinality Any required DAX patterns (example measure) that are production-safe Guidance on handling Budget at Level 3 while reporting down to Level 4 in the same matrix Thanks you.Solved687Views0likes4CommentsAgregate table data on app server or inside power bi
We have an ERP system and each module has many data tables, reference tables with codes and lookup values etc. I have been creating SQL database views for users to access (via XL) entire raw data sets of infrastructure assets combining asset details, financial data, etc. SQL database views can include between 12 to 20 different tables and other views. For data slicing in XL it is very convenient and practical for users. My question is from a PowerBI dashboard perspective would it be better design and 'optimisation' to have star models in Power BI, or accessing the aggregated database views from the ERP database server or create semantic models on the PowerBi server or ... Any recommendation or pointer to best practice guidelines would be much appreciated. Thank youSolved525Views2likes2CommentsRolling 4 hours average
Hi Experts, Add one more column "Rolling 4 hours Average", it has to map current row MIPS value + previous 3 , then divided by 4. we have a slicers to filter by region, by month, by date. after this "Rolling 4 hours Average" created, we have to calculate MAX MIPS value without 4 hours rolling by Month and MAX MIPS value with 4 hours rolling by month. I have tried the below DAX by result is not as expected. Rolling 4h Avg (strict ÷ 4) = VAR RelationDistinct = SUMMARIZE ( ALLSELECTED ( 'VW_MF_TRANSACTIONS' ), 'VW_MF_TRANSACTIONS'[LPAR], 'VW_MF_TRANSACTIONS'[MetricDateTime_1] ) VAR W = WINDOW ( -3, 0, RelationDistinct, ORDERBY ( 'VW_MF_TRANSACTIONS'[MetricDateTime_1], ASC ), PARTITIONBY ( 'VW_MF_TRANSACTIONS'[LPAR] ) ) VAR Sum4 = SUMX ( W, [MAX MIPS]) RETURN DIVIDE ( Sum4, 4 ) Please help to fix this asap. Thanks DK1.1KViews0likes5CommentsHow to programmatically publish Power BI / Power Query Dataflows after deployment (CI/CD scenario)?
Hi all, We are working on implementing CI/CD for Power Platform / Power BI across multiple environments (Dev → UAT → Prod), and we’ve run into a blocker related to publishing dataflows. 🔹 Context: We deploy solutions and artifacts using Azure DevOps pipelines Dataflows are successfully deployed to the target environment However, they remain in an unpublished state until manually opened and published in the UI 🔹 Issue: We are unable to find any supported way to programmatically trigger the “Publish” action for dataflows. 🔹 What we’ve tried: Power Platform CLI (pac) Power BI REST APIs Power Automate (cloud flows) Power Automate Desktop (UI automation approach — not ideal for enterprise pipelines) 🔹 Current limitation: There does not appear to be a supported API to: Publish Dataflow (equivalent to clicking "Publish" in UI) 🔹 Questions: Is there any supported API or mechanism to publish dataflows programmatically? Are there any recommended enterprise patterns for handling this in CI/CD? Is this capability on Microsoft’s roadmap (e.g., Fabric / Dataflow Gen2)? 🔹 Current workaround: We are currently considering: Manual publish step post-deployment Raising a Microsoft support ticket for confirmation #power-bi #dataflows #power-platform #ci-cd #azure-devops #fabric1.5KViews0likes8Comments