REMOVEFILTERS
gælder for:beregnet kolonneberegnet tabelMeasurevisualiseringsberegning
Ryd filters fra de angivne tabeller or kolonner.
Syntaks
REMOVEFILTERS([<table> | <column>[, <column>[, <column>[,…]]]])
Parametre
Begreb | Definition |
---|---|
table | Den tabel, du vil rydde filters på. |
kolonne | Den kolonne, du vil rydde filters på. |
Returner value
NIELSEN. Se bemærkninger.
Bemærkninger
REMOVEFILTERS kan kun bruges til at rydde filters, men not til at returnere en tabel.
Denne funktion understøttes not til brug i DirectQuery-tilstand, når den bruges i beregnede kolonner or RLS-regler (row-level security).
Eksempel 1
DAX forespørgsel
DEFINE
MEASURE FactInternetSales[TotalSales] = SUM(FactInternetSales[SalesAmount])
MEASURE FactInternetSales[%Sales] = DIVIDE([TotalSales], CALCULATE([TotalSales],REMOVEFILTERS()))
EVALUATE
SUMMARIZECOLUMNS(
ROLLUPADDISSUBTOTAL(DimProductCategory[EnglishProductCategoryName], "IsGrandTotal"),
"TotalSales", [TotalSales],
"%Sales", [%Sales]
)
ORDER BY
[IsGrandTotal] DESC, [TotalSales] DESC
Returnerer
DimProductCategory[EnglishProductCategoryName] | [IsGrandTotal] | [TotalSales] | [%Sales] |
---|---|---|---|
Række1 | True | 29358677.2207 | 0 |
Cykler | False | 28318144.6507 | 0.964557920570538 |
Accessories | False | 700759.96 | 0.023868921434441 |
Tøj | False | 339772.61 | 0.0115731579950215 |
Eksempel 2
DAX forespørgsel
DEFINE
MEASURE FactInternetSales[TotalSales] = SUM(FactInternetSales[SalesAmount])
MEASURE FactInternetSales[%Sales] = DIVIDE([TotalSales], CALCULATE([TotalSales],REMOVEFILTERS(DimProductSubcategory[EnglishProductSubcategoryName])))
EVALUATE
SUMMARIZECOLUMNS(
DimProductCategory[EnglishProductCategoryName],
DimProductSubcategory[EnglishProductSubcategoryName],
"TotalSales", [TotalSales],
"%Sales", [%Sales]
)
ORDER BY
DimProductCategory[EnglishProductCategoryName] ASC,
DimProductSubcategory[EnglishProductSubcategoryName] ASC
Returnerer
DimProductCategory [EnglishProductCategoryName] | DimProductSubcategory [EnglishProductSubcategoryName] | [TotalSales] | [%Sales] |
---|---|---|---|
Accessories | Cykelstativer | 39360 | 0.05616759 |
Accessories | Cykelstativer | 39591 | 0.05649723 |
Accessories | Flasker and bure | 56798.19 | 0.08105228 |
Accessories | Rengøringsmidler | 7218.6 | 0.0103011 |
Accessories | Fendere | 46619.58 | 0.06652717 |
Accessories | Hjelme | 225335.6 | 0.3215589 |
Accessories | Hydreringspakker | 40307.67 | 0.05751994 |
Accessories | Dæk and rør | 245529.32 | 0.35037578 |
Cykler | Mountain Bikes | 9952759.564 | 0.35146228 |
Cykler | Road Bikes | 14520584.04 | 0.51276608 |
Cykler | Touring Bikes | 3844801.05 | 0.13577164 |
Tøj | Caps | 19688.1 | 0.05794493 |
Tøj | Handsker | 35020.7 | 0.10307099 |
Tøj | Jerseys | 172950.68 | 0.5090189 |
Tøj | Shorts | 71319.81 | 0.20990453 |
Tøj | Sokker | 5106.32 | 0.01502864 |
Tøj | Veste | 35687 | 0.10503201 |