mysql 的 if 和 SQL server 的 iif 在sql语句中,mysql 使用 if 而SQL server 使用iif 如 mysql : SELECT IF(1<2,'yes ','no'); sql server: SELECT IIF(1<2,'yes ','no');