You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I am using the Graph Explorer web app to test endpoints before adding them to my .NET project. A successful http request should generate a successful code snippet. But when I retrieve the code snippet from this section and attempt to use it in my project it throws the following exception. "Invalid filter clause: Syntax error at position 17 in 'jobtitle ge '!' , accountenabled eq true'."
Here is the code snippet from the graph explorer (that throws an error) var result = await graphClient.Users.GetAsync((requestConfiguration) => { requestConfiguration.QueryParameters.Filter = "jobtitle ge '!' , accountenabled eq true"; requestConfiguration.Headers.Add("ConsistencyLevel", "eventual"); });
And here is the working code var result = await graphClient.Users.GetAsync((requestConfiguration) => { requestConfiguration.QueryParameters.Filter = "jobtitle ge '!' and accountenabled eq true"; requestConfiguration.Headers.Add("ConsistencyLevel", "eventual"); });
To Reproduce
Steps to reproduce the behavior:
Go to Graph Explorer page
Enter a multi-filter http GET https://graph.microsoft.com/v1.0/users?$filter=jobtitle ge '!' &$filter= accountenabled eq true
After successfully running query click Code Snippets tab.
The C# snippet filter is formatted incorrectly.
Expected behavior
I should be able to copy the code form the snippet into my project
The text was updated successfully, but these errors were encountered:
Describe the bug
I am using the Graph Explorer web app to test endpoints before adding them to my .NET project. A successful http request should generate a successful code snippet. But when I retrieve the code snippet from this section and attempt to use it in my project it throws the following exception.
"Invalid filter clause: Syntax error at position 17 in 'jobtitle ge '!' , accountenabled eq true'."
Here is the code snippet from the graph explorer (that throws an error)
var result = await graphClient.Users.GetAsync((requestConfiguration) => { requestConfiguration.QueryParameters.Filter = "jobtitle ge '!' , accountenabled eq true"; requestConfiguration.Headers.Add("ConsistencyLevel", "eventual"); });
And here is the working code
var result = await graphClient.Users.GetAsync((requestConfiguration) => { requestConfiguration.QueryParameters.Filter = "jobtitle ge '!' and accountenabled eq true"; requestConfiguration.Headers.Add("ConsistencyLevel", "eventual"); });
To Reproduce
Steps to reproduce the behavior:
https://graph.microsoft.com/v1.0/users?$filter=jobtitle ge '!' &$filter= accountenabled eq true
Expected behavior
I should be able to copy the code form the snippet into my project
The text was updated successfully, but these errors were encountered: