写在这里,以便于以后忘记格式后可以查询。

CREATE OR REPLACE FUNCTION TEMP_FUNC_WYL(PI_AAA100 VARCHAR2,
PI_AAA102 VARCHAR2)
--字典转换,把代码值转换成对应的可理解的中文,wyl,20141105
RETURN VARCHAR2 IS
V_AAA103 VARCHAR2(1000);
BEGIN
SELECT AAA103
INTO V_AAA103
FROM AA10 A
WHERE A.AAA100 = PI_AAA100
AND A.AAA102 = PI_AAA102;
RETURN V_AAA103;
EXCEPTION
WHEN NO_DATA_FOUND THEN
DBMS_OUTPUT.PUT_LINE('没有找到数据');
END;
04-16 14:03