Modules

filter

 

Objects/Functions

module (N/workbook)

SuiteScript 2.0

workbook.ConditionalFilter

// Please search https://system.netsuite.com/app/help/helpcenter.nl?search=workbook.ConditionalFilter for more information.

N/workbook Module
workbook.ConditionalFilter
Object Description: A conditional filter. A conditional filter can be used when you create a pivot definition or a chart definition. You can create a conditional filter using workbook.createConditionalFilter(options).
Supported Script Types: Server scripts For more information, see SuiteScript 2.0 Script Types.
Module: N/workbook Module
Methods and Properties: ConditionalFilter Object Members
Since: 2020.2
Search NetSuite - https://system.netsuite.com/app/help/helpcenter.nl?search=workbook.ConditionalFilter

Example:

// Code Example 1
// Add additional code
//...
// Create a ConditionalFilter
var myConditionalFilter = workbook.createConditionalFilter({
row: true,
otherAxisSelector: myDimensionSelector,
filteredNodesSelector: myPathSelector,
measure: myMeasure,
predicate: myExpression
});

// View a workbook.ConditionalFilter used in a ChartDefinition and a PivotDefinition
var myWorkbook = workbook.load ({
id: myWorkbookId
});
var myChartDefConditionalFilter = myWorkbook.chartDefinitions[0].aggregationFilters[0];

log.audit({
title: 'Workbook ChartDefinition ConditionalFilter = ',
details: myChartDefConditionalFilter
});

var myPivotDefConditionalFilter = myWorkbook.pivotDefinitions[0].aggregationFilters[0];

log.audit({
title: 'Workbook PivotDefinition ConditionalFilter = ',
details: myPivotDefConditionalFilter
});
//...
// Add additional code

//SOURCE: https://system.netsuite.com/app/help/helpcenter.nl?fid=section_159008152586.html