Hi,
I'm trying to create a custom function and use it in a query. I'm able to create a function in PBI Desktop and then use it in query, but i need to comibne it in a query so instead:
let Source = OData.Feed("https://qa-api.mspmanager.com/odata"), Bills_table = Source{[Name="Bills",Signature="table"]}[Data], Result = Table.AddColumn(Bills_table, "MapValue", each Map(_[AmountBilled])) in Result
where Map is my function, I want to combine this with query. Is this achievable ?
let Map = (val as number) => if val > 10 then "a" else "b" <-- some functino defined before rest of query
let Source = OData.Feed("https://qa-api.mspmanager.com/odata"), Bills_table = Source{[Name="Bills",Signature="table"]}[Data], Result = Table.AddColumn(Bills_table, "MapValue", each Map(_[AmountBilled])) in Result