Quantcast
Channel: jQuery Library for SharePoint Web Services
Viewing all articles
Browse latest Browse all 6517

New Post: Can GetListItems be filtered by item ID?

$
0
0
Hi Marc,

I added the CAMLQuery, but now I'm getting no results:
    var htmlTable = '<table>';
$().SPServices({
    operation: "GetListItems",
    async: false,
    listName: "Attributes",
    CAMLQuery: "<Eq><FieldRef Name='ID'></FieldRef><Value Type='Integer'>758</Value></Eq>",
    CAMLViewFields: "<ViewFields>" +
                "<FieldRef Name='Title' ></FieldRef>" +
                "<FieldRef Name='Values' ></FieldRef>" +
                "<FieldRef Name='ID' ></FieldRef>" +
            "</ViewFields>",
    
    completefunc: function (xData, Status) {
        $(xData.responseXML).SPFilterNode('z:row').each(function() {
            
            htmlTable += "<tr>" +
                "<td>" + $(this).attr("ows_Title") + "</td>" +
                "<td>" + $(this).attr("ows_Values") + "</td>" +
                "<td>" + $(this).attr("ows_ID") + "</td>" +
            "</tr>";
        })
        htmlTable += "</table>";
    }
});

Viewing all articles
Browse latest Browse all 6517

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>