OData4 - Olingo System Query Options ($filter) left object is being passed null
As following this https://olingo.apache.org/doc/odata4/tutorials/sqo_f/tutorial_sqo_f.html documentation.
Get the expression from the query option:
Expression filterExpression = filterOption.getExpression();
Let's assume that the above line of code contains ([ManagerId] eq 1) query.
which means ManagerId is the left Object
eq is the operator
1 is the right object
And under looping over all entities in the collection and calculate the result of the expression for a given entity:
Object visitorResult = filterExpression.accept(expressionVisitor);
So, whenever the accept() method is being called, it invokes the visitBinaryOperator(BinaryOperatorKind operator, Object left, Object right) method of ExpressionVisitor interface implementation. At the moment the visitBinaryOperator() method is invoked the left object is being passed null.
This is the actual root cause, would be great to know the tips and tricks from the folks. Thanks in advance!.
java odata olingo
add a comment |
As following this https://olingo.apache.org/doc/odata4/tutorials/sqo_f/tutorial_sqo_f.html documentation.
Get the expression from the query option:
Expression filterExpression = filterOption.getExpression();
Let's assume that the above line of code contains ([ManagerId] eq 1) query.
which means ManagerId is the left Object
eq is the operator
1 is the right object
And under looping over all entities in the collection and calculate the result of the expression for a given entity:
Object visitorResult = filterExpression.accept(expressionVisitor);
So, whenever the accept() method is being called, it invokes the visitBinaryOperator(BinaryOperatorKind operator, Object left, Object right) method of ExpressionVisitor interface implementation. At the moment the visitBinaryOperator() method is invoked the left object is being passed null.
This is the actual root cause, would be great to know the tips and tricks from the folks. Thanks in advance!.
java odata olingo
add a comment |
As following this https://olingo.apache.org/doc/odata4/tutorials/sqo_f/tutorial_sqo_f.html documentation.
Get the expression from the query option:
Expression filterExpression = filterOption.getExpression();
Let's assume that the above line of code contains ([ManagerId] eq 1) query.
which means ManagerId is the left Object
eq is the operator
1 is the right object
And under looping over all entities in the collection and calculate the result of the expression for a given entity:
Object visitorResult = filterExpression.accept(expressionVisitor);
So, whenever the accept() method is being called, it invokes the visitBinaryOperator(BinaryOperatorKind operator, Object left, Object right) method of ExpressionVisitor interface implementation. At the moment the visitBinaryOperator() method is invoked the left object is being passed null.
This is the actual root cause, would be great to know the tips and tricks from the folks. Thanks in advance!.
java odata olingo
As following this https://olingo.apache.org/doc/odata4/tutorials/sqo_f/tutorial_sqo_f.html documentation.
Get the expression from the query option:
Expression filterExpression = filterOption.getExpression();
Let's assume that the above line of code contains ([ManagerId] eq 1) query.
which means ManagerId is the left Object
eq is the operator
1 is the right object
And under looping over all entities in the collection and calculate the result of the expression for a given entity:
Object visitorResult = filterExpression.accept(expressionVisitor);
So, whenever the accept() method is being called, it invokes the visitBinaryOperator(BinaryOperatorKind operator, Object left, Object right) method of ExpressionVisitor interface implementation. At the moment the visitBinaryOperator() method is invoked the left object is being passed null.
This is the actual root cause, would be great to know the tips and tricks from the folks. Thanks in advance!.
java odata olingo
java odata olingo
edited Nov 28 '18 at 13:19
Abdul Gaffar
asked Nov 24 '18 at 7:42
Abdul GaffarAbdul Gaffar
1911415
1911415
add a comment |
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53456192%2fodata4-olingo-system-query-options-filter-left-object-is-being-passed-null%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53456192%2fodata4-olingo-system-query-options-filter-left-object-is-being-passed-null%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown