I am using the Lists web-service interface to SharePoint 2010 to get the items in a list. I want each returned row to have the ID FieldRef of the item but no other FieldRefs.
I specify a view fields parameter in my request like so:
<ViewFields><FieldRef Name="ID" /></ViewFields>
The view name parameter is unspecified so the default view should be used.
As per the documentation I would expect it to override the default list view and return only those FieldRefs that I have specified. In my case that would be just the ID but it also includes others (from the default view?).
I have also tried adding query options to remove mandatory columns (I tried both true and false for this value):
Is there a way to enforce that the results will only have my specified FieldRefs and no others? My next step is to create a temporary view with my desired FieldRef configuration but I'd prefer to not have to do that if possible and the documentation suggests what I am trying with the view fields parameter should work.
The reason I want to do this is that ows_MetaInfo contains an invalid character reference for some of my SharePoint data that chokes my web-service client and so I don't want it in the results.