ISEMPTY DAX Function (Information)
Returns true if the specified table or table-expression is Empty.
Syntax
Parameter | Attributes | Description |
---|---|---|
Table |
Table or table-expression. |
Return values
TRUE if the table is empty (has no rows), if else, FALSE.
Examples
-- ISEMPTY checks that a table contains no rows -- -- This example retrieves the products with sales in 2007 and -- no sales in 2008 by using ISEMPTY EVALUATE VAR ProductsSales = ADDCOLUMNS ( TOPN ( 10, VALUES ( 'Product'[Product Name] ) ), "HasSalesIn2007", NOT ISEMPTY ( CALCULATETABLE ( Sales, 'Date'[Calendar Year] = "CY 2007" ) ), "NoSalesIn2008", ISEMPTY ( CALCULATETABLE ( Sales, 'Date'[Calendar Year] = "CY 2008" ) ) ) VAR Result = FILTER ( ProductsSales, [NoSalesIn2008] = TRUE && [HasSalesIn2007] = TRUE ) RETURN Result
Related articles
Learn more about ISEMPTY in the following articles:
-
Check Empty Table Condition with DAX
In DAX there are different ways to test whether a table is empty. This test can be used in complex DAX expressions and this short article briefly discuss what are the suggested approaches from a performance perspective. » Read more
-
Syncing slicers in Power BI
The June 2019 update of Power BI includes the ability to filter slicer items based on a measure. This article explains why this is an important feature that should replace bidirectional filters used for the same purpose. » Read more
-
Using tuple syntax in DAX expressions
This article describes the use of the tuple syntax in DAX expressions to simplify comparisons involving two or more columns. » Read more
-
Finding products without sales by using DAX
This article analyzes the performance of different DAX techniques to identify any products without sales in an area or a time period. » Read more
Last update: Nov 1, 2024 » Contribute » Show contributors
Contributors: Alberto Ferrari, Marco Russo
Microsoft documentation: https://docs.microsoft.com/en-us/dax/isempty-function-dax