List.IsEmpty

Updated on

List.IsEmpty is a Power Query M function that checks if a list is empty. The function returns true if the list is empty, and false if it contains values.

Compatible with: Power BI Service Power BI Desktop Excel Microsoft 365

Syntax

List.IsEmpty( list as list ) as logical

Description

Returns true if the list, list, contains no values (length 0). If the list contains values (length > 0), returns false.

Examples

Find if the list {} is empty.

// Output: true
List.IsEmpty( {} )

Find if the list {1, 2} is empty.

// Output: false
List.IsEmpty( {1, 2} )

Other functions related to List.IsEmpty are:

Contribute » | Contributors: Rick de Groot
Microsoft documentation: https://learn.microsoft.com/en-us/powerquery-m/list-isempty