This project has moved and is read-only. For the latest updates, please go here.

Query A ProjectProperty With GetListItems

Sep 18, 2012 at 1:59 AM

Hey guys I was just wondering if it's possible to include a ProjectProperty with the GetListItems function?  I'm unfortunately not getting much luck.  I'm trying to query the Description property below.

var myQuery = "<Query><Where><BeginsWith><FieldRef Name='ContentType' /><Value Type='Text'>News</Value></BeginsWith></Where></Query>";
	operation: "GetListItems",
	async: false,
	listName: "Pages",
	CAMLViewFields: "<ViewFields><FieldRef Name='Title' /><ProjectProperty Name='Description' /></ViewFields>",
	CAMLRowLimit: 5,
	completefunc: function (xData, Status) {
		$(xData.responseXML).SPFilterNode("z:row").each(function () {

Sep 18, 2012 at 5:03 PM

I haven't ever tried it, frankly. What are you getting in the results?


Sep 19, 2012 at 2:56 PM

Well, the query completes successfully, however, I'm not quite sure how to reference that property.  I know I start off with ows_ to get FieldRef properties, but what would I use for ProjectProperty?  I've tried a bunch of stuff with no luck.  I also tried to view the "raw" xData, but I see no reference to the ProjectProperty in there, so I don't think that's a good sign.

Sep 19, 2012 at 9:54 PM

I just tried your code above, and I don't see the ProjectProperty coming back, either.


Sep 20, 2012 at 12:25 AM

If I wanted to get the name of a Site does that functionality exist in SPServices?

Sep 20, 2012 at 2:02 AM

Take a look at GetWeb. It gives you the Web's Title and Description