How to dump SP parameters & values ?
360862Jan 31 2003 — edited Feb 4 2003Hi,
I wonder If there is anyway to dump Stored Procedure parameter names and their values into string, let's say for Error Logging (vs. to explicitly and manually for every routine out of tons of them append string to a variable) ?
For example function in Package :
FUNCTION CREATE_BUSINESS_KEY_FNC (
iLOC_ID IN CUSTOMER_XREF_BV.LOC_ID%TYPE,
iORDER_NO IN SERVICE_BV.LOCID_ORDER_NUM%TYPE) RETURN SERVICE_BV.LOCID_ORDER_NUM%TYPE IS
vPARAM_DUMP VARCHAR2(2000);
BEGIN
... Do Work ...
EXCEPTION
WHEN OTHERS THEN
-- Does anything else exists better then below, it's pain (what If I have 50 + params in every routine ?) --
vPARAM_DUMP := 'iLOC_ID = ' || iLOC_ID || ', iORDER_NO = ' || iORDER_NO;
ERR_LOG_HANDLER_PRC(SQLCODE, SQLERRM,
'CREATE_BUSINESS_KEY_FNC', vPARAM_DUMP);
RETURN NULL;
END CREATE_BUSINESS_KEY_FNC;
Please Help !
Thanx !