Get ListItem by id without loading the List first, is it possible? #1227
Unanswered
CodingJarod
asked this question in
Q&A
Replies: 1 comment 2 replies
-
@CodingJarod : this is not possible today, if you can cache the |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I was wondering whether it is possible to load a specific list item by id without having to execute a double request.
The normal way to retrieve an item by id is the following:
but it makes a double web request.
The IList interface has a method to retrieve the list in a batch but the IListItem does not have a batch version of the GetByIdAsync method.
I've tried to do the following
But on the ExecuteAsync an exception is throw with the message 'Property Id was not yet loaded' unless execute
before loading the list item, getting back to the double web request.
In the standard CSOM model it was possible. Is there any way to do so in the SDK?
Thanks in advance.
Beta Was this translation helpful? Give feedback.
All reactions