Wednesday, December 8, 2010

Minor gotcha with owssvr URL queries

Sorry for the lack of posting recently, I had to gear up quickly for a relocation, and now that I'm mostly settled in my new house, it's time to get back on track!

I encountered an issue today in some forms I've been working on. I was using a URL query into SharePoint to get an XML-formatted subset of list items from a SharePoint list. If you're unfamiliar with this, you can essentially use a URL in the following format to get an XML-formatted chunk of data from SharePoint and process it however you like:


I have an InfoPath form that's using this to populate a drop-down list. We'd never expected this list to get long, but the business unit involved grew this list from 15 entries to more than 120 in between versions, and I suddenly found that the list was not returning all the items.

It turns out that the data returned using this method is partially affected by the settings for the Default View for that list. The default setting for SharePoint views usually limits list output to batches of 100. I upped this to 1000, and now I get all my list items. Fantastic!

No comments:

Post a Comment