List.First
This topic applies to the Power Query Formula Language which can be used with Power Query and Power BI Desktop to build queries that mashup data. See the list of function categories.
Returns the first value of the list or the specified default if empty. Returns the first item in the list, or the optional default value, if the list is empty. If the list is empty and a default value is not specified, the function returns.
List.First(list as list, optional defaultValue as any) as any
| Argument | Description |
|---|---|
| list | The List to check. |
| optional defaultValue | Default value if list is empty. |
List.First({1, 2, 3}) equals 1
List.First({}) equals null
Show: