What is the REST URI that does the same as the CAML Query shown here

This CAML Query (works great):


This is what I have tried, to no avail:

.../Items?$filter=(substringof('laptop',ItemDescription)) AND (ItemRef ne '0000000000')

The error I get from SharePoint is:

The expression "(substringof('laptop',ItemDescription)) AND (ItemRef ne '0000000000')" is not valid."

Thank you very much!

  • What is the data type of "ItemDescription" and "ItemRef" columns? Jun 17, 2022 at 12:17
  • Both are type text fields. It seems the problem was the capital AND... So silly :) its often times the simple things that get us!
    – snugam
    Jun 20, 2022 at 3:44

1 Answer 1


Try changing and in the filter to lower case.

.../Items?$filter=(substringof('laptop',ItemDescription)) and (ItemRef ne '0000000000')

  • As simple as that -- I must have been tired. Fixed! Thank you very much!
    – snugam
    Jun 20, 2022 at 3:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.