我正在处理一个重载的包,想知道两件事。
1)有没有办法获得更多关于发生了什么错误的信息,比如它发生在什么行号上,因为Failed to resolve object details
接缝有点模糊。
2) 这个陈述似乎有什么问题?
CREATE OR REPLACE PACKAGE shop_query_pkg IS
procedure shop_info
(p_id IN bb_shopper.idshopper%TYPE,
p_firstname out bb_shopper.firstname%TYPE);
procedure shop_info
(p_id IN bb_shopper.lastname%TYPE,
p_firstname out bb_shopper.firstname%TYPE);
END;
/
CREATE OR REPLACE PACKAGE BODY show_query_pkg IS
procedure shop_info
(p_id IN bb_shopper.idshopper%TYPE,
p_firstname out bb_shopper.firstname%TYPE);
IS
BEGIN
SELECT firstname
into p_firstname
FROM bb_shopper
WHERE idshopper = p_id;
EXCEPTION
WHEN NO_DATA_FOUND THEN
DBMS_OUTPUT.PUT_LINE('ID does not exist');
END;
-- second procedure
procedure shop_info
(p_id IN bb_shopper.lastname%TYPE,
p_firstname out bb_shopper.firstname%TYPE);
IS
BEGIN
SELECT firstname
into p_firstname
FROM bb_shopper
WHERE lastname = p_id;
EXCEPTION
WHEN NO_DATA_FOUND THEN
DBMS_OUTPUT.PUT_LINE('Last name does not exist');
END;
END;
/
show errors;
错误
PACKAGE shop_query_pkg compiled
PACKAGE BODY show_query_pkg compiled
Warning: execution completed with warning
Failed to resolve object details