Rest APIs are resource full while working with Sharepoint 2013 and Jquery . I had a simple scenario where I wanted to show only list items created by logged in users .
During the filter by AuthorId I came across this issue
Column 'AuthorId' does not exist. It may have been deleted by another user
Resolution
When all columns in
url: _spPageContextInfo.webAbsoluteUrl + "/_api/web/lists/getByTitle('Your List name')/items?&$filter=Author eq "+ userid +"&$orderby=Created desc",
When selected columns
url: _spPageContextInfo.webAbsoluteUrl + "/_api/web/lists/getByTitle('Your List name')/items?&$filter=Author eq "+ userid +"&$select=Col1 , col2,AuthorId, &expand=Author&$orderby=Created desc",
No comments:
Post a Comment