Symptom
In transaction VK12, after deleting a record with a zero scale value and attempting to edit the record again, the new scale record cannot be saved. The system throws a dump as described below:
Category ABAP programming error
Runtime Errors DBSQL_DUPLICATE_KEY_ERROR
Except. CX_SY_OPEN_SQL_DB
ABAP Program SAPLV13A
Application Component SD-MD-CM
Short Text
Open SQL array insert produces duplicate records in the database.
What happened?
Error in the ABAP application program.
The current ABAP program "SAPLV13A" had to be terminated because it found a
statement that could not be executed.
...
Error analysis
An exception has occurred which is explained in more detail below. The
exception is assigned to class 'CX_SY_OPEN_SQL_DB' and was not caught in
procedure
"KONM_CHANGE" "(FORM)", nor was it 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 is:
When an Open SQL array insert is performed, trying to insert a record
into the database table "KONM" 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.)
Read more...
Environment
- Sales And Distribution (SD)
- Logistics Execution (LE)
- SAP R/3
- SAP R/3 Enterprise 4.7
- SAP ERP Central Component
- SAP ERP
- SAP Enhancement package for SAP ERP
- SAP Enhancement package for SAP ERP, version for SAP HANA
- SAP S/4HANA
- S/4HANA Cloud Private Edition
Product
Keywords
dbsql_duplicate_key_error, runtime error, scale value zero, VK12, SAPLV13A, CX_SY_OPEN_SQL_DB, condition maintenance, pricing condition, SAP S/4HANA, KONM table, duplicate entry, scale type, V/06. , KBA , SD-MD-CM , Conditions and Condition Maintainance , 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.