Hi Sreeniavs,
The exception is never caught at "CATCH zcx_bw_sd_code INTO gl_cx.". It get's caught in the calling method of the start routine as cx_root. I have my code in the start routine of a BW transformation. Basically an exit in a SAP BW generated program where user code can be added. So the calling method is:
...
TRY.
i_r_log->add_substep( 'ROUTS' ).
*<<< Rule ID: '47'.
_curr_rule-ruleid = '47'.
* Step ID: '1', Type: 'ROUTINE'.
_curr_rule-stepid = '1'.
CALL METHOD me->start_routine <-----This method is where I write my code.
EXPORTING
request = l_request
datapackid = i_r_inbound->n_datapakid
IMPORTING
monitor = _lt_msg_s
CHANGING
SOURCE_PACKAGE = <_yt_SC_1>.
...
CATCH cx_root INTO lr_cx_root. <---This is where the exception gets caught.
If I change my declaration of gl_cx to "type ref to cx_root", and the catch line to "CATCH cx_root INTO gl_cx." then the line catches the exception but as errid "UNCAUGHT_EXCEPTION".
Image may be NSFW.
Clik here to view.
Regards,
Dae Jin