POSTING_ILLEGAL_STATEMENT
highIllegal ABAP Statement Executed During Database Posting
Module: ABAP / FI
What this means
POSTING_ILLEGAL_STATEMENT fires when an ABAP program executes a statement that is not permitted within a posting sequence — specifically during update task execution (VB work process). Update task programs run in a restricted environment where certain statements like CALL SCREEN, MESSAGE TYPE I/A/W, or user interaction statements are forbidden. This is most commonly seen in: custom FI/CO posting exits that include interactive statements; update function modules (flagged with V1 or V2) that contain forbidden calls; or standard update functions that were modified incorrectly.
Check ST22 for the exact statement. Review SM13 for the update request that failed. Identify the update function module (typically visible in the call stack) and check its code for forbidden statements. Replace interactive messages with application log entries (SLG1). Remove any CALL SCREEN or user-dialog patterns. After fixing, the update request in SM13 may need to be repeated if it was left in error status.
Quick Info