IFNULL

Learn how to use the IFNULL condition function in PlaidCloud Lakehouse. Returns the first expression if it is not NULL, otherwise returns the second expression.

Returns the first expression if it is not NULL, otherwise returns the second expression.

Analyze Syntax

func.ifnull(get_column(table, 'phone'), 'N/A')

Analyze Examples

func.ifnull(get_column(table, 'phone'), 'N/A')

SQL Syntax

IFNULL(<phone>, 'N/A')

SQL Examples

SELECT name, IFNULL(phone, 'N/A') AS phone FROM contacts;

┌─────────┬──────────┐
 name     phone    
├─────────┼──────────┤
 Alice    555-1234 
 Bob      N/A      
└─────────┴──────────┘