Using CASE...WHEN for evaluating conditions
mysql> mysql> SELECT CASE WHEN 9>7 THEN "TRUE" ELSE "FALSE" END AS "Results"; +---------+ | Results | +---------+ | TRUE | +---------+ 1 row in set (0.00 sec)