创建Oracle银行家舍入算法函数过程
银行家舍入算法规则描述:四舍六入五考虑,五后非零就进一,五后为零看奇偶,五前为偶应舍去,五前为奇要进一函数过程:CREATE OR REPLACEFUNCTION ROUND2 (P1 IN NUMBER, P2 IN NUMBER) RETURN NUMBER ASBEGINIF TRUNC (P1, P2 + 1) <> P1OR SUBSTR (P1 * POWER(10, P2 + 1) ,- 1) <> '5'OR MOD (SU