Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I am trying to know how throttling in SharePoint affects web services.

For example if a list contains 20 000 items and throttling is set to 2000, if I use the Lists.GetListItems() method to get the items what will the result be? Will it contains 2000 or an error message?

Thank you for your time.

share|improve this question

2 Answers 2

up vote 2 down vote accepted

It will give you an error message. Additionally, it also depends through which user account this code has been called as Administrators have different thresholds for listview than a regular user.

Edit:

The exception message will be:

The attempted operation is prohibited because it exceeds the list view threshold enforced by the administrator.

share|improve this answer
    
Can you add a link or reference that describes this error? (The form of the XML returned...) –  user3470 May 24 '12 at 7:41
    
I edited your question to add the exception message. Thanks. –  user3470 May 24 '12 at 8:56

If you are running code as Farm Admin throttling settings are ignored and you can retrieve as much data as you need.

If you are a site collection administrator 'List View Threshold for Auditors and Administrators' applies, so by default you are limited to 20.000 list items.

Otherwise 'List View Threshold' will apply.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.