WITH t AS (
SELECT 0 ad from dual UNION ALL SELECT 1 FROM DUAL)
SELECT DECODE(AD,0,0-NULL,AD) from t;
此为数值。
WITH t AS (
SELECT 0 ad from dual UNION ALL SELECT 1 FROM DUAL)
SELECT DECODE(AD,0,NULL,AD) from t;
此为字符。
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/11990065/viewspace-749587/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/11990065/viewspace-749587/