ISEMPTY
A
C
- CALCULATE
- CALCULATETABLE
- CALENDAR
- CALENDARAUTO
- CEILING
- CHISQ.DIST
- CHISQ.DIST.RT
- CHISQ.INV
- CHISQ.INV.RT
- CLOSINGBALANCEMONTH
- CLOSINGBALANCEQUARTER
- CLOSINGBALANCEYEAR
- COALESCE
- COLUMNSTATISTICS
- COMBIN
- COMBINA
- COMBINEVALUES
- CONCATENATE
- CONCATENATEX
- CONFIDENCE.NORM
- CONFIDENCE.T
- CONTAINS
- CONTAINSROW
- CONTAINSSTRING
- CONTAINSSTRINGEXACT
- CONVERT
- COS
- COSH
- COT
- COTH
- COUNT
- COUNTA
- COUNTAX
- COUNTBLANK
- COUNTROWS
- COUNTX
- COUPDAYBS
- COUPDAYS
- COUPDAYSNC
- COUPNCD
- COUPNUM
- COUPPCD
- CROSSFILTER
- CROSSJOIN
- CUMIPMT
- CUMPRINC
- CURRENCY
- CURRENTGROUP
- CUSTOMDATA
D
E
I
N
O
P
R
S
- SAMEPERIODLASTYEAR
- SAMPLE
- SEARCH
- SECOND
- SELECTCOLUMNS
- SELECTEDMEASURE
- SELECTEDMEASUREFORMATSTRING
- SELECTEDMEASURENAME
- SELECTEDVALUE
- SIGN
- SIN
- SINH
- SLN
- SQRT
- SQRTPI
- STARTOFMONTH
- STARTOFQUARTER
- STARTOFYEAR
- STDEVX.P
- STDEVX.S
- STDEV.P
- STDEV.S
- SUBSTITUTE
- SUBSTITUTEWITHINDEX
- SUM
- SUMMARIZE
- SUMMARIZECOLUMNS
- SUMX
- SWITCH
- SYD
T
U
What is ISEMPTY?
ISEMPTY is a DAX function used to check whether a given expression is empty or not. The expression can be a column, a table, or a value. The ISEMPTY function returns a Boolean value – TRUE if the expression is empty, and FALSE if it’s not.
Here’s the syntax of the ISEMPTY function:
ISEMPTY(❰expression❱)
The expression parameter can be any valid DAX expression, such as a column, a table, or a value.
How to Use ISEMPTY
Now that we know what ISEMPTY is, let's see how to use it in Power BI. Here are a few examples:
Example 1: Checking for Empty Columns
Suppose you have a table called Sales that contains three columns - ProductName, SalesAmount, and Profit. You want to check whether the Profit column is empty or not. Here's how you can do it using the ISEMPTY function:
=ISEMPTY(Sales[Profit])
The above DAX expression will return TRUE if the Profit column is empty, and FALSE if it's not.
Example 2: Checking for Empty Tables
Suppose you have two tables - Sales and Expenses. You want to check whether the Expenses table is empty or not. Here's how you can do it using the ISEMPTY function:
=ISEMPTY(Expenses)
The above DAX expression will return TRUE if the Expenses table is empty, and FALSE if it's not.
Example 3: Using ISEMPTY in Calculated Columns
Suppose you have a table called Customers that contains two columns - CustomerName and Country. You want to create a new calculated column called CountryIsEmpty that checks whether the Country column is empty or not. Here's how you can do it using the ISEMPTY function:
1. Go to the Fields pane and select the Customers table.
2. Click on the New Column button in the Modeling tab.
3. Enter the following DAX expression:
CountryIsEmpty = ISEMPTY(Customers[Country])
4. Press Enter to create the new calculated column.
The above DAX expression will create a new column called CountryIsEmpty that returns TRUE if the Country column is empty for a given row, and FALSE if it's not.
In this article, we discussed the ISEMPTY function in Power BI. We saw how to use it to check whether a given expression is empty or not, and saw a few examples of how it can be used in practice. The ISEMPTY function is a powerful tool in the Power BI arsenal and can help you create more accurate and insightful reports and dashboards.