dataset.loadDataset.promise(options)

Method Description

Asynchronously loads an existing dataset.

Note:

The parameters and errors thrown for this method are the same as those for dataset.loadDataset(options). For more information on promises, see Promise Object.

Returns

Promise Object

Synchronous Version

dataset.loadDataset(options)

Supported Script Types

Server scripts

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

Governance

10 units

Module

N/dataset Module

Sibling Module Members

N/dataset Module Members

Since

2020.2

Parameters

Note:

The options parameter is a JavaScript object.

Parameter

Type

Required / Optional

Description

options.id

string

required

The ID of the dataset to load.

Syntax

Important:

The following code sample shows the syntax for this member. It is not a functional example. For a complete promise script example, see Promise Object.

            // Add additional code
...
dataset.loadDataset.promise({
    id: myDatasetId    // Use a script ID from an existing script
}).then(function(dataset){
    // process the dataset object
});
...
// Add additional code 

          

Related Topics

General Notices