task.MapReduceScriptTask

Note:

The content in this help topic pertains to SuiteScript 2.0.

Object Description

The properties of a map/reduce script deployment. You can use this object to programmatically submit a script deployment for processing.

To use the MapReduceScriptTask object:

  • In the NetSuite UI, create the script record and script deployment records.

  • Use task.create(options) to create the MapReduceScriptTask object.

  • Use the MapReduceScriptTask object properties to set the script and deployment properties.

  • Use MapReduceScriptTask.submit() to submit the deployment for processing.

  • Use the properties for the task.MapReduceScriptTaskStatus object to get the status of the map/reduce script.

For a complete list of this object’s methods and properties, see MapReduceScriptTask Object Members.

For general information about map/reduce scripts, see Map/Reduce Key Concepts.

Supported Script Types

Server scripts

For more information, see SuiteScript 2.x Script Types.

Module

N/task Module

Since

2015.2

Syntax
Important:

The following code sample shows the syntax for this member. It is not a functional example. For a complete script example, see N/task Module Script Samples.

          //Add additional code 
...
var mrTask = task.create({
    taskType: task.TaskType.MAP_REDUCE
});
mrTask.scriptId = mapReduceScriptId;
mrTask.deploymentId = custdeploy1;
var mrTaskId = mrTask.submit();
...
//Add additional code 

        
Note:

For general information about map/reduce scripts, see SuiteScript 2.x Map/Reduce Script Type.

Related Topics

N/task Module
SuiteScript 2.x Modules
SuiteScript 2.x

General Notices