sql if else mysql的相關文章
sql if else mysql的相關商品

MySQL 'IF' in 'SELECT' statement - Stack Overflow
瀏覽:852
日期:2025-04-29
SELECT id , IF(type = 'P', amount, amount * -1) as amount FROM report See this http://dev.mysql.com/doc/refman/5.0/en/control-flow-functions.html Additionaly you can handle when condition is null. So in the case of amount could be null. SELECT ......看更多