Forum Discussion
Formula.Firewall: Please rebuild this data combination.
I am sorry but I don't understand. By what should I replace it?
I need to query this table to get the list of items.
Thanks,
Brice
Do not refer it on the other query, copy the code that queries it from the source.
Try writing the query without dependencies.
You can use disable the parallel load tables for performance issues, so it will query just once.
- Brice_LE-LANN6 years agoRegular Visitor
(thanks for the reactivity)
My "otherTable" is exactly extracted from API calls. To be clear, I have:
- one query which calls an API (get Items), extract some values. (I do some graphs on those value)
- for some of those items, I want to do another API call to get different data
You advise me to:
- one query which calls an API (get Items), extract some values. (I do some graphs on those value)
- create another query which will call the same API, and for each of the value, do another call.
So I do not have depencies (but I call the first API twice).
Is that correct?
- camargos886 years ago
Community Champion
- Brice_LE-LANN6 years agoRegular Visitor
I am afraid I can't, there is too much data to hide.
I can share the first query though:
let myKey = "xxx", pageLimit = 2, myPageSize= 2, order = "-modificationDate", FnGetOnePage = (pageId) as record => let HTTPHeader = [Query = [pageSize = Number.ToText(myPageSize), page = Number.ToText(pageId), sort = order], Headers = [#"Ocp-Apim-Subscription-Key" = apimKey ]], Source = Json.Document(Web.Contents("https://url.com", HTTPHeader)), count = try Source[count] otherwise null, values = try Source[values] otherwise null, results = [Count=count, Values=values] in results, data = List.Generate( () => [pageId=1, result = FnGetOnePage(pageId)], each [pageId]<= pageLimit and [result][Values] <> {}, each [pageId=[pageId]+1, result = [result] & FnGetOnePage(pageId) ] ), output = Table.FromRecords(data), allValues = Table.ExpandRecordColumn(output, "result", {"Count", "Values"}, {"result.Count", "result.Values"}), expendedAllValues = Table.ExpandListColumn(allValues, "result.Values"), #"Expanded result.Values" = Table.ExpandRecordColumn(expendedAllValues, "result.Values", {"key", "filteringValue"}, {"key", "filteringValue"}) in #"Expanded result.Values"