7
votes
Why can I not filter it inside my REST API end point
If you want to filter on lookup field, you need to expand those lookup for filtering.
Try the following query:
/_api/web/lists/getbytitle('Projects')/items?$filter=SiteAutomaticallyCreated eq '...
7
votes
Why can I not filter it inside my REST API end point
Your filter expression looks malformed, you join them by and, not a comma. Try the below.
You'd have a request like:
/_api/web/lists/getbytitle('Projects')/items?$filter=SiteAutomaticallyCreated eq '...
6
votes
REST API Getting Fields from an Lookup List
When creating lookup field, you can select which field from source list you want to show. The number of such fields is limited by field type. For example you can create a lookup with lookup field ...
6
votes
Accepted
Sharepoint REST api - Recursively fetch all folders in a document library -
I think you should use CAML query with REST API.
Here you can find your solution on this answer by Vadim Gremyachev
Sample code provided by Vadim Gremyachev:
function getListItems(webUrl,listTitle, ...
4
votes
Accepted
Get data from SharePoint Folder using Power BI
Regarding error message : the remote server returned an error : (404) Not Found
Make sure that the provided URL is the site URL and not list URL.
For more details check OData Connection Errors
...
4
votes
How to group distinct values from a list using odata rest api
I know it's a relatively old post but, for anyone who's still looking for an answer on this, querying for both grouping and aggregations(Totals) is supported in REST. Following are the two links for ...
3
votes
Accepted
CAML Query vs Odata Query string operators
A few benefits of REST ODATA queries:
Much easier to write.
Generally more readable and obvious to another developer.
Might be a tiny bit faster, but probably not enough to notice. (The ODATA query ...
3
votes
How to get details of editor of SharePoint site file?
Try using below endpoint:
/_api/SP.AppContextSite(<host web url>)/web/lists('2c955ea0-28h4-4f84-a8b5-001df9be12b')/getitembyid(93)?$select=Title,Editor/ID,Editor/Title&$expand=Editor
OR:
...
3
votes
Expanding columns in lookup fields
Consider your lookup column name as "Field1LUP" of "List1"
and "Title" field of "List2" is source to lookup field.
/_api/web/lists(guid'<guid>')/items?$select=Field1LUP/Title&$expand=...
2
votes
System.UnauthorizedAccessException Access Denied REST
This is a known issue with this endpoint. It works only if you are site admin or owner.
Instead of /_api/web/webs endpoint, you need to use /_api/web/getsubwebsfilteredforcurrentuser endpoint. It ...
2
votes
Accepted
How to filter data where a field contains a something with OData
Looks to be an issue with SharePoint.
UserVoice - Fix REST FileRef queries
However, you can use the getitems POST method along with CAML query to retrieve the items as below:
var queryText = '<...
2
votes
Accepted
Sharepoint dll for querying an ODATA API
First thing, you won`t see the Microsoft.SharePoint.dll for SharePoint add-in and console application running on remote system. You must use Microsoft.SharePoint.Client.dll which you can get it from ...
2
votes
Accepted
Downloading data from over 90 SharePoint Team sub-sites
I was able to solve the problem in a way that fits a business user skill set, probably not the best possible way, but one I could accomplish.
Started out with the list of sites i had to access, on a ...
2
votes
How to get details of editor of SharePoint site file?
You can use the below rest on success of your request in the question using the EditorId.
/_api/SP.AppContextSite(@target)/web/getuserbyid(EditorId)?@target='<host web url>'
2
votes
Column 'ServerRedirectedEmbedUrl' does not exist. Rest odata SPOnline
I messed around with this for a bit and I don't think the property is filterable. That means you'll have to request a bigger result set and filter it on the success function. It would look something ...
2
votes
Accepted
Filter SharePoint list by multichoice column for exact match
The short answer is to construct the query so that it excludes all the other possible values. So lets say you only have 4 options, you could do
/_api/web/lists(<GUID>)/items?$filter=Field eq '...
1
vote
CAML Query vs Odata Query string operators
Based on my experience, I think Odata query selectors are better in performance.
As it gets only those particular data.
However, in case of Caml query, it gets the data based on the rest url and then ...
1
vote
Accepted
When calling SharePoint REST OData api, what is the biggest value allowed by $top?
I think its limit is 5000. If you want to have more than that you can utilize batching or make multiple calls or paging.
1
vote
Change Sharepoint task parent id via REST
Probably, you just missed a comma in the JSON between fields:
{
"Name":"NewName",
"ParentId":"5b5369a8-e0b9-e911-910f-001dd8b71c8d"
}
Also, as far as I remember the ParentID is a lookup ...
1
vote
Accepted
Is there a limit of conditions count for oData query using $filter?
Generally you shouldn't query with so many conditions unless it is really necessary.
Following is a workaround which you can try.
If there are limitations in REST api multiple query conditions then ...
1
vote
Sharepoint 2013 REST API GetFolderByServerRelativeUrl will not return the Author details
Umh, afaik you cant get more than that without requesting the listitem.
_api/web/lists/getbytitle('Documents')/items?$expand=Author&$select=Author/FirstName,Author/Id,Author/LastName
Props:
...
1
vote
Downloading data from over 90 SharePoint Team sub-sites
Your best chances might be to go for the SharePoint Search, as it already does the aggregation continuously by crawling the contents of the (sub) sites.
You might want to have a look at the SharePoint ...
1
vote
Accepted
Still getting Odata Service Connector Throttle Error - Already tried Set-SPBusinessDataCatalogThrottleConfig
Looks like you cannot use Scope Database, and ThrottleType Items.
You need to use Scope OData, and ThrottleType Size.
Scope : OData
ThrottleType : Size
Enforced : False
Default : ...
1
vote
How to get items from a SharePoint List by list URL path using Javascript REST API?
your query is extracting the lists,
if you want to extract the list items you need to wo write a new query to request an specific list and then extract its items :
http://site url/_api/web/lists/...
1
vote
How to add aliases in SharePoint rest query?
To get the Domain\username in your Spreadsheet column, you need to create single line text column column called UserName and assign the =Me value in Calculated Value text box. This column will give ...
1
vote
Filter list with REST
Use this rest query
/_api/web/lists/getbytitle(list title)/items?$expand=lookUpCol/Id&$filter=lookUpCol/Id eq 4
It should work.
1
vote
Accepted
Filter list with REST
To filter lookup columns you have to use expand and filter properties.
First mention the property in select statement and expand then apply filter
Use Ajax Get Request,
var select = "$select=...
1
vote
REST API + Expand Recurring Calendar Events?
Another approach is to fetch the calendar items using REST Api and expand the recurring events using SPEventsParser library(GitHub repository).
first Get the calendar items using REST like this:
/...
1
vote
Failed to create list item for external list using REST API POST
I have a code which may be useful for you.
Try this-
function CreateListItemWithDetails(listName, webUrl, newItemTitle) {
var itemType = GetItemTypeForListName(listName);
var item = {
"...
1
vote
REST Api Filtered odata returning error: list view threshold
If you have list items more than 5000, or you are anticipating you might have items more than 5000 in the future then the best practice is to make rest call in more than 1 batches of 5000 starting ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
odata × 149rest × 66
sharepoint-online × 42
2013 × 25
sharepoint-rest-api × 23
sharepoint-enterprise × 11
2010 × 9
javascript × 9
bcs × 8
external-content-type × 8
sharepoint-server × 7
list × 7
filter × 7
jquery × 6
excel × 6
sharepoint-addin × 5
ajax × 5
wcf × 5
development × 4
sharepoint-foundation × 4
csom × 4
client-object-model × 4
caml-query × 4
json × 4
excel-services × 4