Dataset.save(options)
Method Description |
Saves a dataset. When you save a dataset, you must provide a name, which will appear in the SuiteAnalytics Workbook UI. Optionally, you can provide a description and an ID. If you do not provide an ID, one is generated automatically. The object returned from this method includes only the |
Returns |
Object |
Supported Script Types |
Server scripts For more information, see SuiteScript 2.x Script Types. |
Governance |
10 |
Module |
|
Parent Object |
|
Sibling Object Members |
|
Since |
2020.2 |
Parameters
The options
parameter is a JavaScript object.
Parameter |
Type |
Required / Optional |
Description |
---|---|---|---|
|
string | workbook.Expression |
required |
The name of the dataset. |
|
string | workbook.Expression |
optional |
The description of the dataset. |
|
string |
optional |
The ID of the dataset. |
Errors
Error Code |
Thrown If |
---|---|
|
The value of the |
Syntax
The following code sample shows the syntax for this member. It is not a functional example. For a complete script example, see N/dataset Module Script Samples. Also see the Tutorial: Creating a Dataset Using the Workbook API topic.
// Add additional code
...
// Create and save a new dataset
var myNewDataset = dataset.create({
type: 'transaction',
columns: [myDatasetColumns]
});
myNewDataset.save({
name: 'My Dataset',
description: 'This is a sample dataset.',
id: 'custdataset_myDataset'
});
...
// Add additional code