This example shows how to change the filtering in Related Data tables. When you have multiple data tables that are related to each other in your analysis, and the data tables do not include exactly the same rows, you may want to handle filtering in the related data tables in different ways, depending on whether you are interested in the filtered rows or the filtered out rows
Introduction
This example shows how to change the filtering in Related Data tables. When you have multiple data tables that are related to each other in your analysis, and the data tables do not include exactly the same rows, you may want to handle filtering in the related data tables in different ways, depending on whether you are interested in the filtered rows or the filtered out rows. The different options are,
- Include Filtered Rows Only
- Exclude Filtered Out Rows
- Ignore Filtering
Code Sample
# Copyright © 2017. TIBCO Software Inc. Licensed under TIBCO BSD-style license. from Spotfire.Dxp.Data import DataFilteringSelection, RelatedRowsPropagation from Spotfire.Dxp.Application.Filters import FilteringSchemeCollection, FilteringScheme, FilterCollection toTable=Document.Data.Tables["table1"] fromTable=Document.Data.Tables["table2"] DataFilteringSelection=Document.ActiveFilteringSelectionReference #To Include Filtered Rows Only DataFilteringSelection.SetRelationPropagationBehavior(toTable,fromTable,RelatedRowsPropagation.OnlyMatching) #To Exclude Filtered Out Rows #DataFilteringSelection.SetRelationPropagationBehavior(toTable,fromTable,RelatedRowsPropagation.IncludeNonMatching) #To Ignore Filtering #DataFilteringSelection.SetRelationPropagationBehavior(toTable,fromTable,RelatedRowsPropagation.Ignore)
References
- API Reference: DataFilteringSelection
- API Reference: DataFilteringSelection.SetRelationPropagationBehavior Method
- API Reference: RelatedRowsPropagation
License: TIBCO BSD-Style License
Recommended Comments
There are no comments to display.