共用方式為


AdvancedFilterBuilder class

Power BI 進階篩選產生器元件

Extends

繼承的屬性

target

方法

addCondition(AdvancedFilterConditionOperators, string | number | boolean | Date)

在進階篩選中新增條件


// Add two conditions
const advancedFilterBuilder = new AdvancedFilterBuilder().addCondition("Contains", "Wash").addCondition("Contains", "Park");
and()

設定 And 作為進階篩選的邏輯運算元


const advancedFilterBuilder = new AdvancedFilterBuilder().and();
build()

建立進階篩選


const advancedFilterBuilder = new AdvancedFilterBuilder().build();
or()

設定 或 作為進階篩選的邏輯運算元


const advancedFilterBuilder = new AdvancedFilterBuilder().or();

繼承的方法

withColumnAggregation(string, string, string)

使用數據行匯總目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withColumnAggregation(tableName, columnName, aggregationFunction);
withColumnTarget(string, string)

使用資料行目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withColumnTarget(tableName, columnName);
withHierarchyLevelAggregationTarget(string, string, string, string)

使用階層層級匯總目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withHierarchyLevelAggregationTarget(tableName, hierarchy, hierarchyLevel, aggregationFunction);
withHierarchyLevelTarget(string, string, string)

使用階層層級目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withHierarchyLevelTarget(tableName, hierarchy, hierarchyLevel);
withMeasureTarget(string, string)

使用量值目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withMeasureTarget(tableName, measure);
withTargetObject(IFilterTarget)

使用目標物件設定篩選的目標屬性

const target = {
 table: 'table1',
 column: 'column1'
};

const filterBuilder = new FilterBuilder().withTargetObject(target);

繼承的屬性詳細資料

target

target: IFilterTarget

屬性值

繼承自FilterBuilder.target

方法詳細資料

addCondition(AdvancedFilterConditionOperators, string | number | boolean | Date)

在進階篩選中新增條件


// Add two conditions
const advancedFilterBuilder = new AdvancedFilterBuilder().addCondition("Contains", "Wash").addCondition("Contains", "Park");
function addCondition(operator: AdvancedFilterConditionOperators, value?: string | number | boolean | Date): AdvancedFilterBuilder

參數

value

string | number | boolean | Date

傳回

and()

設定 And 作為進階篩選的邏輯運算元


const advancedFilterBuilder = new AdvancedFilterBuilder().and();
function and(): AdvancedFilterBuilder

傳回

build()

建立進階篩選


const advancedFilterBuilder = new AdvancedFilterBuilder().build();
function build(): AdvancedFilter

傳回

or()

設定 或 作為進階篩選的邏輯運算元


const advancedFilterBuilder = new AdvancedFilterBuilder().or();
function or(): AdvancedFilterBuilder

傳回

繼承的方法的詳細資料

withColumnAggregation(string, string, string)

使用數據行匯總目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withColumnAggregation(tableName, columnName, aggregationFunction);
function withColumnAggregation(tableName: string, columnName: string, aggregationFunction: string): AdvancedFilterBuilder

參數

tableName

string

columnName

string

aggregationFunction

string

傳回

繼承自FilterBuilder.withColumnAggregation

withColumnTarget(string, string)

使用資料行目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withColumnTarget(tableName, columnName);
function withColumnTarget(tableName: string, columnName: string): AdvancedFilterBuilder

參數

tableName

string

columnName

string

傳回

繼承自FilterBuilder.withColumnTarget

withHierarchyLevelAggregationTarget(string, string, string, string)

使用階層層級匯總目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withHierarchyLevelAggregationTarget(tableName, hierarchy, hierarchyLevel, aggregationFunction);
function withHierarchyLevelAggregationTarget(tableName: string, hierarchy: string, hierarchyLevel: string, aggregationFunction: string): AdvancedFilterBuilder

參數

tableName

string

hierarchy

string

hierarchyLevel

string

aggregationFunction

string

傳回

繼承自filterBuilder.withHierarchyLevelAggregationTarget

withHierarchyLevelTarget(string, string, string)

使用階層層級目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withHierarchyLevelTarget(tableName, hierarchy, hierarchyLevel);
function withHierarchyLevelTarget(tableName: string, hierarchy: string, hierarchyLevel: string): AdvancedFilterBuilder

參數

tableName

string

hierarchy

string

hierarchyLevel

string

傳回

繼承自FilterBuilder.withHierarchyLevelTarget

withMeasureTarget(string, string)

使用量值目標物件設定篩選的目標屬性

const filterBuilder = new FilterBuilder().withMeasureTarget(tableName, measure);
function withMeasureTarget(tableName: string, measure: string): AdvancedFilterBuilder

參數

tableName

string

measure

string

傳回

繼承自FilterBuilder.withMeasureTarget

withTargetObject(IFilterTarget)

使用目標物件設定篩選的目標屬性

const target = {
 table: 'table1',
 column: 'column1'
};

const filterBuilder = new FilterBuilder().withTargetObject(target);
function withTargetObject(target: IFilterTarget): AdvancedFilterBuilder

參數

target
IFilterTarget

傳回

繼承自FilterBuilder.withTargetObject