Symptom
- When you try to activate your custom workflow template from SWDD you receive a dump that mentions "SWD_STORE_WF_CONDITION"
- Condition of type IF does not suit step xxx. Do you want to delete it? Message No. WD717
Category ABAP programming error
Runtime Errors DBSQL_DUPLICATE_KEY_ERROR
Except. CX_SY_OPEN_SQL_DB
ABAP Program SAPLSWDB
Application Component BC-BMT-WFM
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|Short Text |
| Open SQL array insert produces duplicate records in the database. |
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|What happened? |
| Error in the ABAP application program. |
| |
| The current ABAP program "SAPLSWDB" had to be terminated because it found a |
| statement that could not be executed. |
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|Error analysis |
| An exception has occurred in class "CX_SY_OPEN_SQL_DB". This exception was not |
| caught |
| in procedure "SWD_STORE_WF_CONDITION" "(FUNCTION)" or propagated by a RAISING |
| clause. |
| Since the caller of the procedure could not have anticipated this |
| exception, the current program was terminated. |
| The reason for the exception occurring was: |
| The reason for the exception is: |
| When an Open SQL array insert is performed, trying to insert a record |
| into the database table "SWD_CONDEF" causes the function to terminate if a |
| record with the same key already exists. |
| |
| (When an Open SQL individual record insert is performed, this situation |
| does not cause the function to terminate. SY-SUBRC is set to 4 instead.) |
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|How to correct the error |
| If the exception cannot be prevented, "CX_SY_OPEN_SQL_DB" must be caught within |
| procedure "SWD_STORE_WF_CONDITION" "(FUNCTION)" or declared in the procedure's |
| RAISING clause. |
| To prevent the exception, note the following: |
| |
| Open SQL array insert should only be used if it is certain that none of |
| the records specified already exists on the database. If this cannot be |
| guaranteed, exception CX_SY_OPEN_SQL_DB should be intercepted, and the |
| error must be resolved. |
| If the error occurs in a non-modfied SAP program, you might be able to |
| find a solution in the SAP Notes system. If you have access to the SAP |
| Notes system, check there first using the following keywords: |
| |
| "DBSQL_DUPLICATE_KEY_ERROR" CX_SY_OPEN_SQL_DB |
| "SAPLSWDB" bzw. LSWDBU49 |
| "SWD_STORE_WF_CONDITION" |
| If you cannot solve the problem yourself, please send the following |
| information to SAP: |
| |
----------------------------------------------------------------------------------------------------
|Active Calls/Events |
----------------------------------------------------------------------------------------------------
|No. Ty. Program Include Line |
| Name |
----------------------------------------------------------------------------------------------------
| 13 FUNCTION SAPLSWDB LSWDBU49 54 |
| SWD_STORE_WF_CONDITION |
| 12 FUNCTION SAPLSWDB LSWDBU09 178 |
| SWD_STORE_WORKFLOW_DATA |
| 11 FUNCTION SAPLSWDA LSWDAU10 579 |
| SWD_ACTIVATE_WORKFLOW |
| 10 FORM SAPLSWDD LSWDDF30 369 |
| SSC_WD_ACTIVATE |
| 9 FUNCTION SAPLSWDD LSWDDU12 85 |
| SWD_WORKFLOW_ACTIVATE |
| 8 FORM SAPLSWDD LSWDDF90 2180 |
| WORKFLOW_DEFINITION_ACTIVATE |
| 7 FORM SAPLSWDD LSWDDF05 258 |
| EXECUTE_OKCODE_WORKFLOW |
| 6 FUNCTION SAPLSWDD LSWDDU07 155 |
| SWD_EXECUTE_OKCODE |
| 5 FORM SAPLSWDD LSWDDF15 163 |
| D0450_EXECUTE_CMD |
| 4 MODULE (PAI) SAPLSWDD LSWDDI50 2078 |
| D0430_EXECUTE_CMD |
| 3 FORM SAPLSWDD LSWDDF20 294 |
| WORKFLOW_GRAPHIC_START |
| 2 FUNCTION SAPLSWDD LSWDDU01 365 |
| SWD_INVOKE_WORKFLOW_EDITOR |
| 1 EVENT RSWDSTRT RSWDSTRT 31 |
| START-OF-SELECTION |
----------------------------------------------------------------------------------------------------
Read more...
Environment
- SAP Business Workflow
-
SAP NetWeaver
- SAP Web Application Server for SAP S/4 HANA
- ABAP PLATFORM - Application Server ABAP
Product
Keywords
WF_GDPR, SWF_WORKFLOW, Syntax check, condition, switch, case, editor , KBA , BC-BMT-WFM , Business Workflow , Problem
About this page
This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP for Me (Login required).Search for additional results
Visit SAP Support Portal's SAP Notes and KBA Search.