If the package ISNULL function in MYSQL

Before using the NVL function to determine which function in Oracle, now wants to write a name in the MySQL called NVL, the function of the realization of ISNULL, the purpose is to not change the code, thank you!

Started by Franklin at November 25, 2016 - 5:09 AM

MySQL has isnull function, why write function

Posted by Claude at December 04, 2016 - 5:22 AM

MySql has a IFNULL () function estimation can satisfy you

Posted by Geoffrey at December 14, 2016 - 5:37 AM

+1


mysql> SELECT IFNULL(1,0);
-> 1
mysql> SELECT IFNULL(NULL,10);
-> 10
mysql> SELECT IFNULL(1/0,10);
-> 10
mysql> SELECT IFNULL(1/0,'yes');
-> 'yes'

Posted by Allison at December 26, 2016 - 5:58 AM