Was wondering how to return the results of my save...
# suitescript
s
Was wondering how to return the results of my saved search for a RESTlet GET Request?
var salesorderSearchObj = search.create({
type: "salesorder",
filters:
[
["type","anyof","SalesOrd"],
"AND",
["custbody_status","anyof","16"],
"AND",
["mainline","is","T"]
],
columns:
[
search.createColumn({
name: "entity",
sort: search.Sort.ASC,
label: "Name"
})
]
var searchResultCount = salesorderSearchObj.runPaged().count;
salesorderSearchObj.run().each(function(result){
// .run().each has a limit of 4,000 results
??????????????
return true;
});
return JSON.stringify(results);
}//end GET Request