SS 2.0 来自已保存的搜索

require(['N/search'], function(SEARCHMODULE){
    var savedSearchId = 'customsearch_mySavedSearch';
    var mySearch = SEARCHMODULE.load(savedSearchId);
    var resultset = mySearch.run();
    var results = resultset.getRange(0, 1000);
    for(var i in results){
        var result = results[i];
        for(var k in result.columns){
            log.debug('Result is ' + result.getValue(result.columns[k])); //Access result from here
        }
    }
});