Best way to get req information from large data set returned in spservices

Oct 15, 2013 at 6:56 AM
Hi
I am using spservice to get list items but prob is, for the logic i need to build caml query can not be optimised much and result of that is I am getting a large data in xData. Now i dont need to iterate through all the data as I need some specific information only.

I tried using something like $(xData.responseXML).SPFilterNode("z:row").filter("my logic") but it gives me Stop Running this script warning in browser.

How can I optimise this part where i need to find specific nodes in xData.responseXML.
Coordinator
Oct 15, 2013 at 3:28 PM
You can do any valid filtering, so your filter is probably not valid.

More important, client side code isn't always the right answer. If you're pulling too much data across for the client to handle, it's time to rethink your architecture.

M.
Oct 16, 2013 at 3:41 AM
Edited Oct 16, 2013 at 3:42 AM
Thanks Marc !
I think this makes sense too much of data will create problems at client side.

Is there any limit on no. of items in a list which we can query using spservices?
Coordinator
Oct 16, 2013 at 4:13 AM
It depends on SharePoint version. In 2010+, there are list throttling limits, usually set at 5000. Realistically, though, that's a lot of data to pull across to the client side, anyway. There are times when it makes sense, and times when it doesn't.

M.
Oct 16, 2013 at 10:40 AM
Thanks Marc !
Oct 16, 2013 at 1:14 PM
Let me also add that my experience with throttling is that once it is triggered (ex. >5000) WebServices stop working. Just about all queries fail at that point even if the result of the filter provided was less that the threshold. See this post: https://spservices.codeplex.com/discussions/280642


Paul


--

_________
Paul T