ODATA filter records based on lookup field

Hi Community,

Currently I am not able to filter record using ODATA for my lookup field, I am getting object reference error. Below is my request string.

UsrEmiratesId is the lookup field

"UsrAreaCollection?$top=1000&$filter=UsrEmiratesId eq guid'" + emirateId + "'&select=Id, Name, UsrEmiratesId"


But when I filter the record using Id which the PK column, request is successful, what is wrong with this lookup field why it is not working


Like 0



Dear Fulgen,

The possible reason for an error could be in syntax of lookup in the request. Please try to modify the request string, so that you filter by UsrEmirates/Id. For example, as if I would like to select orders with certain opportunitites, I would filter by Opportunity/Id

Hope you find it helpful,


Show all comments