2008 Feb 22 4:03 AM
HI,
Runtime errors can occur during execution of bundled updates. How are they handled?
2008 Feb 22 6:04 AM
HI,
In general, COMMIT WORK processing occurs in the following order:
...
1. All dialog-task FORM routines logged with PERFORM ON COMMIT are executed.
2. All high-priority (V1) update-task function modules are executed.
The end of V1-update processing marks the end of the change transaction. If you used COMMIT WORK AND WAIT to trigger commit processing, control returns to the dialog-task program.
3. All low-priority (V2) update-task function modules are triggered.
All background-task function modules are triggered.
Runtime errors can occur either in the system itself, or because your program issues an termination message (MESSAGE type A). Also, the ROLLBACK WORK statement automatically signals a runtime error. The system handles errors according to where they occur:
in a FORM routine (called with PERFORM ON COMMIT)
Updates already executed for the current update transaction are rolled back.
(ii)No other FORM routines will be started.
(iii) No further update-task or background-task functions will be started.
(iv) An error message appears on the screen.
in a V1 update-task function module (requested IN UPDATE TASK)
(i)Updates already executed for V1 functions are rolled back.
(ii)All further update-task requests (V1 or V2) are thrown away.
(iii)All background-task requests are thrown away.
(iv)Updates already executed for FORM routines called with PERFORM ON COMMIT are not rolled back.
(v)An error message appears on the screen, if your system is set up to send them
in a V2 update-task function module (requested IN UPDATE TASK)
(i)Updates already executed for the current V2 function are rolled back.
(ii)All update-task requests (V2) still to be executed are discarded.
(iii) All background-task requests still to be executed are carried out.
(iv)No updates for previously executed V1 functions are rolled back.
(v)No updates previously executed for FORM routines (called with ON COMMIT) are rolled back.
(vi) An error message appears on the screen, if your system is set up to send them
in a background-task function module (requested IN BACKGROUND TASK DESTINATION)
Background-task updates already executed for the current DESTINATION are not rolled back.
(ii) All further background-task requests for the same DESTINATION are thrown away.
(iii)Other previously executed updates are rolled back.
(iv)No error message appears on the screen.
If your program detects that an error in remote processing has occurred, it can decide whether to resubmit the requests at a later time.
For further information about RFC processing, refer to the Remote Communications documentation.
Reward Points if found helpfull..
Cheers,
Chandra Sekhar.
HI,
Runtime errors can occur during execution of bundled updates. How are they handled?
2008 Feb 22 6:04 AM
HI,
In general, COMMIT WORK processing occurs in the following order:
...
1. All dialog-task FORM routines logged with PERFORM ON COMMIT are executed.
2. All high-priority (V1) update-task function modules are executed.
The end of V1-update processing marks the end of the change transaction. If you used COMMIT WORK AND WAIT to trigger commit processing, control returns to the dialog-task program.
3. All low-priority (V2) update-task function modules are triggered.
All background-task function modules are triggered.
Runtime errors can occur either in the system itself, or because your program issues an termination message (MESSAGE type A). Also, the ROLLBACK WORK statement automatically signals a runtime error. The system handles errors according to where they occur:
in a FORM routine (called with PERFORM ON COMMIT)
Updates already executed for the current update transaction are rolled back.
(ii)No other FORM routines will be started.
(iii) No further update-task or background-task functions will be started.
(iv) An error message appears on the screen.
in a V1 update-task function module (requested IN UPDATE TASK)
(i)Updates already executed for V1 functions are rolled back.
(ii)All further update-task requests (V1 or V2) are thrown away.
(iii)All background-task requests are thrown away.
(iv)Updates already executed for FORM routines called with PERFORM ON COMMIT are not rolled back.
(v)An error message appears on the screen, if your system is set up to send them
in a V2 update-task function module (requested IN UPDATE TASK)
(i)Updates already executed for the current V2 function are rolled back.
(ii)All update-task requests (V2) still to be executed are discarded.
(iii) All background-task requests still to be executed are carried out.
(iv)No updates for previously executed V1 functions are rolled back.
(v)No updates previously executed for FORM routines (called with ON COMMIT) are rolled back.
(vi) An error message appears on the screen, if your system is set up to send them
in a background-task function module (requested IN BACKGROUND TASK DESTINATION)
Background-task updates already executed for the current DESTINATION are not rolled back.
(ii) All further background-task requests for the same DESTINATION are thrown away.
(iii)Other previously executed updates are rolled back.
(iv)No error message appears on the screen.
If your program detects that an error in remote processing has occurred, it can decide whether to resubmit the requests at a later time.
For further information about RFC processing, refer to the Remote Communications documentation.
Reward Points if found helpfull..
Cheers,
Chandra Sekhar.
2008 Feb 22 6:08 AM
Hi ,
Use the following code.
DATA : error_obj_ref TYPE REF TO cx_root.
TRY.
Update ztable FROM TABLE itab.
CATCH cx_sy_open_sql_db INTO error_obj_ref.
error_text = error_obj_ref->get_text( ).
MESSAGE i398(00) WITH add your text here.'.
ENDTRY.
Reward if helpfull
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |