Forum Discussion

MuzammilAK's avatar
MuzammilAK
New Member
2 years ago

Use Query option in Web.Content and pass $filter

Dears,

 

I am trying to pass $filter as query parameter to Web.Contents, so that I can enable scheduled refresh.

 

 

 

url = GetGraphURL(AzureKind)&"/"&TenantName&"/users",
queryParameters = [
        #"api-version" = 1.6,
        #"$filter" = "objectId eq '"&principalId&"'"
        // Add any other query parameters here
    ],
 Source = Json.Document(Web.Contents(url,[Query=queryParameters])),

 

 

 

The above does not work.

 

However, if I pass url without Query option in Web.Content, as shown below, it works.

 

 

 

url = GetGraphURL(AzureKind)&"/"&TenantName&"/users?api-version=1.6&$filter=objectId eq '"&principalId&"'",
 
Source = Json.Document(Web.Contents(url)),

 

 

But this does not support scheduled refreshing.

 

Please advise.

 

Thank you.

 

1 Reply

  • what is the error message? 

     

    BTW, for scheduled refresh you will also need to use RelativePath.