cube.increment
Adds a value to what is already in a cube cell, instead of replacing it like cube.set does.
js
cube.increment(value, cubeName, ...elements)Use it when several rows of data land on the same cell, such as adding up individual transactions into a monthly total.
Parameters
| Parameter | Type | Description |
|---|---|---|
value | number | The amount to add to the cell. |
cubeName | string | The cube's name. |
elements | string | One element per dimension, in the cube's dimension order. |
Returns
stringThe cell's new total, or a message starting with "Error:" when it fails.
Examples
js
cube.increment(100, "General Ledger", "Actual", "2014", "600010", "100 - Finance", "No Project", "Amount");