Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi! Can someone who understands M language help me? The people in the sector responsible gave me a SAS Token to connect the BI to a DB. In BI, I clicked Web and Web From, inserted the 3 parts of the SAS Token and in HTTP request header I chose Accept and inserted "application / json; odata = nometadata", as per industry guidance.
Thus, BI brought a table of 1000, but the original table has 27000 rows.
I researched and found this site https://medium.com/@martijnlentink/azure-table-storage-in-power-bi-with-a-shared-access-signature-to... where the guy suggests a solution.
But even running the provided scripts, I was not successful. As I understand it, the scritp asks for 3 arguments, I made countless attempts but it didn't work. I don't understand what I should do. Could you help me with this, please?
I'm trying with this script
let
Base64Encode = (str as text) => Binary.ToText (Text.ToBinary (str, BinaryEncoding.Base64)),
CreateContinuationTokens = (partitionkey as text, rowkey as text) =>
let
tokenPrefix = "1",
combineToken = "!",
encodedPartition = Base64Encode (partitionkey),
encodedRow = Base64Encode (rowkey),
nextPartKey = Text.Combine ({tokenPrefix, Text.From (Text.Length (encodedPartition)), encodedPartition}, combineToken),
nextRowKey = Text.Combine ({tokenPrefix, Text.From (Text.Length (encodedRow)), encodedRow}, combineToken),
result = [NextPartitionKey = nextPartKey, NextRowKey = nextRowKey]
in
result,
Func = (url as text, query as record, optional continuationTokens as record) =>
let
queryCombine = if continuationTokens = null then query else Record.Combine ({query, continuationTokens}),
result = Json.Document (Web.Contents (url, [Headers = [Accept = "application / json; odata = nometadata"], Query = queryCombine])),
resultAsList = result [value],
lastInList = List.Last (resultAsList),
tokens = CreateContinuationTokens (lastInList [PartitionKey], lastInList [RowKey]),
resultList = if List.Count (resultAsList)> 1 then List.Combine ({resultAsList, RecursiveTableStorage (url, query, tokens)}) else resultAsList
in
resultList
in
Func
@Anonymous , if are looking for Token based Auth, refer if these can help
https://www.youtube.com/watch?v=f7HLyiAk-lQ
https://community.powerbi.com/t5/Desktop/Connect-to-data-with-API-token/td-p/731867
https://chris.koester.io/index.php/2015/07/16/get-data-from-twitter-api-with-power-query/
https://docs.microsoft.com/en-us/rest/api/power-bi/embedtoken
User | Count |
---|---|
75 | |
75 | |
45 | |
31 | |
27 |
User | Count |
---|---|
99 | |
89 | |
52 | |
48 | |
46 |