Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

SAPSQL_ARRAY_INSERT_DUPREC dump in SPAM on phase CHECK_INACT_OBJECTS

Former Member
0 Likes
574

Hi, Guru!

I'm try  to import SAPKE60092, on the phase CHECK_INACT_OBJECTS system dumped SAPSQL_ARRAY_INSERT_DUPREC.

Runtime Errors         SAPSQL_ARRAY_INSERT_DUPREC

Exception              CX_SY_OPEN_SQL_DB

Date and Time          18.05.2013 00:06:10

|Short Text                                                                                                                      |

|    The ABAP/4 Open SQL array insert results in duplicate database records.                       |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|What happened?                                                                                    |

|    Error in the ABAP Application Program                                                         |

|                                                                                                  |

|    The current ABAP program "SAPLSPAM" had to be terminated because it has                       |

|    come across a statement that unfortunately cannot be executed.                                |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|What can you do?                                                                                  |

|    Note down which actions and inputs caused the error.                                          |

|                                                                                                  |

|                                                                                                  |

|    To process the problem further, contact you SAP system                                        |

|    administrator.                                                                                |

|                                                                                                  |

|    Using Transaction ST22 for ABAP Dump Analysis, you can look                                   |

|    at and manage termination messages, and you can also                                          |

|    keep them for a long time.                                                                    |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|Error analysis                                                                                    |

|    An exception occurred that is explained in detail below.                                      |

|    The exception, which is assigned to class 'CX_SY_OPEN_SQL_DB', was not caught                 |

|     in                                                                                           |

|    procedure "SPAM_CHECK_INACTIVE_OBJECTS" "(FUNCTION)", nor was it propagated by                |

|     a RAISING clause.                                                                            |

|    Since the caller of the procedure could not have anticipated that the                         |

|    exception would occur, the current program is terminated.                                     |

|    The reason for the exception is:                                                              |

|    If you use an ABAP/4 Open SQL array insert to insert a record in                              |

|    the database and that record already exists with the same key,                                |

|    this results in a termination.                                                                |

|                                                                                                  |

|    (With an ABAP/4 Open SQL single record insert in the same error                               |

|    situation, processing does not terminate, but SY-SUBRC is set to 4.)                          |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|How to correct the error                                                                          |

|    Use an ABAP/4 Open SQL array insert only if you are sure that none of                         |

|    the records passed already exists in the database.                                            |

|                                                                                                  |

|    If the error occures in a non-modified SAP program, you may be able to                        |

|    find an interim solution in an SAP Note.                                                      |

|    If you have access to SAP Notes, carry out a search with the following                        |

|    keywords:                                                                                     |

|                                                                                                  |

|    "SAPSQL_ARRAY_INSERT_DUPREC" "CX_SY_OPEN_SQL_DB"                                              |

|    "SAPLSPAM" or "LSPAMU85"                                                                      |

|    "SPAM_CHECK_INACTIVE_OBJECTS"                                                                 |

|                                                                                                  |

|    If you cannot solve the problem yourself and want to send an error                            |

|    notification to SAP, include the following information:                                       |

|                                                                                                  |

|    1. The description of the current problem (short dump)                                        |

|                                                                                                  |

|       To save the description, choose "System->List->Save->Local File                            |

|    (Unconverted)".                                                                               |

|                                                                                                  |

|    2. Corresponding system log                                                                   |

|                                                                                                  |

|       Display the system log by calling transaction SM21.                                        |

|       Restrict the time interval to 10 minutes before and five minutes                           |

|    after the short dump. Then choose "System->List->Save->Local File                             |

|    (Unconverted)".                                                                               |

|                                                                                                  |

|    3. If the problem occurs in a problem of your own or a modified SAP                           |

|    program: The source code of the program                                                       |

|       In the editor, choose "Utilities->More                                                     |

|    Utilities->Upload/Download->Download".                                                        |

|                                                                                                  |

|    4. Details about the conditions under which the error occurred or which                       |

|    actions and input led to the error.                                                           |

|                                                                                                  |

|    The exception must either be prevented, caught within proedure                                |

|    "SPAM_CHECK_INACTIVE_OBJECTS" "(FUNCTION)", or its possible occurrence must be                |

|     declared in the                                                                              |

|    RAISING clause of the procedure.                                                              |

|    To prevent the exception, note the following:                                                 |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|System environment                                                                                |

|    SAP-Release 700                                                                               |

|                                                                                                  |

|    Application server... " "                                                               |

|    Network address...... " "                                                            |

|    Operating system..... "AIX"                                                                   |

|    Release.............. "5.3"                                                                   |

|    Hardware type........ "00CB187E4C00"                                                          |

|    Character length.... 16 Bits                                                                  |

|    Pointer length....... 64 Bits                                                                 |

|    Work process number.. 1                                                                       |

|    Shortdump setting.... "full"                                                                  |

|                                                                                                  |

|    Database server... " "                                                                  |

|    Database type..... "ORACLE"                                                                   |

|    Database name..... "SID"                                                                      |

|    Database user ID.. "SAPSR3"                                                                   |

|                                                                                                  |

|    Terminal................. "laptop"                                                   |

|                                                                                                  |

|    Char.set.... "C"                                                                              |

|                                                                                                  |

|    SAP kernel....... 700                                                                         |

|    created (date)... "Feb 15 2011 11:58:56"                                                      |

|    create on........ "AIX 2 5 005DD9CD4C00"                                                      |

|    Database version. "OCI_102 (10.2.0.2.0) "                                                     |

|                                                                                                  |

|    Patch level. 289                                                                              |

|    Patch text.. " "                                                                              |

|                                                                                                  |

|    Database............. "ORACLE 10.1.0.*.*, ORACLE 10.2.0.*.*, ORACLE 11.2.*.*.*"               |

|    SAP database version. 700                                                                     |

|    Operating system..... "AIX 1 5, AIX 2 5, AIX 3 5, AIX 1 6, AIX 1 7"                           |

|                                                                                                  |

|    Memory consumption                                                                            |

|    Roll.... 16192                                                                                |

|    EM...... 25139088                                                                             |

|    Heap.... 0                                                                                    |

|    Page.... 73728                                                                                |

|    MM Used. 10611768                                                                             |

|    MM Free. 6144424                                                                              |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|User and Transaction                                                                              |

|                                                                                                  |

|    Client.............. 000                                                                      |

|    User................ "DDIC"                                                                   |

|    Language key........ "E"                                                                      |

|    Transaction......... "SPAM "                                                                  |

|    Transactions ID..... "5196119A6CC912E0E10080000A400349"                                       |

|                                                                                                  |

|    Program............. "SAPLSPAM"                                                               |

|    Screen.............. "SAPMSPAM 0100"                                                          |

|    Screen line......... 30                                                                       |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|Information on where terminated                                                                   |

|    Termination occurred in the ABAP program "SAPLSPAM" - in                                      |

|     "SPAM_CHECK_INACTIVE_OBJECTS".                                                               |

|    The main program was "SAPMSPAM ".                                                             |

|                                                                                                  |

|    In the source code you have the termination point in line 128                                 |

|    of the (Include) program "LSPAMU85".                                                          |

|    The termination is caused because exception "CX_SY_OPEN_SQL_DB" occurred in                   |

|    procedure "SPAM_CHECK_INACTIVE_OBJECTS" "(FUNCTION)", but it was neither                      |

|     handled locally nor declared                                                                 |

|    in the RAISING clause of its signature.                                                       |

|                                                                                                  |

|    The procedure is in program "SAPLSPAM "; its source code begins in line                       |

|    1 of the (Include program "LSPAMU85 ".                                                        |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|Source Code Extract                                                                               |

----------------------------------------------------------------------------------------------------

|Line |SourceCde                                                                                   |

----------------------------------------------------------------------------------------------------

|   98|    ENDIF.                                                                                  |

|   99|                                                                                            |

|  100|*   (5) Collect in GT_E071 those objects in the queue which are inactive                    |

|  101|    IF ls_abort_here-yes = off.                                                             |

|  102|*     mark inactive objects                                                                 |

|  103|      PERFORM mark_inactive_objects TABLES   lt_e071                                        |

|  104|                                             lt_inact_obj                                   |

|  105|                                    CHANGING lv_answer                                      |

|  106|                                             lv_rc.                                         |

|  107|*     Handle failure.                                                                       |

|  108|      IF lv_rc <> gc_retcode_ok.                                                            |

|  109|        ls_abort_here-yes    = on.                                                          |

|  110|        ls_abort_here-reason = 'CANNOT_CHECK_INACT_OBJS'.                                   |

|  111|      ENDIF.                                                                                |

|  112|    ENDIF.                             "ls_abort_here = OFF                                 |

|  113|                                                                                            |

|  114|*   (6) If at least one object is inactive save these objects in                            |

|  115|*       table PAT02 for later display                                                       |

|  116|    IF ls_abort_here-yes = off AND                                                          |

|  117|       lv_answer         = on.                                                              |

|  118|      REFRESH lt_pat02.                                                                     |

|  119|      CLEAR ls_pat02.                                                                       |

|  120|      LOOP AT lt_inact_obj INTO ls_e071.                                                    |

|  121|        ls_pat02-patch = ls_e071-trkorr.                                                    |

|  122|        ls_pat02-addonid = 'INACT_OBJS'.                                                    |

|  123|        MOVE-CORRESPONDING ls_e071 TO ls_pat02.                                             |

|  124|        APPEND ls_pat02 TO lt_pat02.                                                        |

|  125|      ENDLOOP.                                              "at lt_e071                     |

|  126|                                                                                            |

|  127|*     was performed at the beginning of the step                                            |

|>>>>>|      INSERT pat02 FROM TABLE lt_pat02.                                                     |

|  129|      fill_message 'S' 'TN' '760' space space space space.                                  |

|  130|      append_logline '3' 'E' space.                                                         |

|  131|      ls_abort_here-yes    = on.          "Abort anyway                                     |

|  132|      ls_abort_here-reason = 'SHOW_DETAIL_AND_DECIDE'.                                      |

|  133|    ENDIF.                             "ls_abort_here = OFF                                 |

|  134|                                                                                            |

|  135|*   (7) Update queue status.                                                                |

|  136|    LOOP AT tt_pat01.                                                                       |

|  137|      IF ls_abort_here-yes = on.          "Step aborted                                     |

|  138|        tt_pat01-stepcond = gc_step_aborted.                                                |

|  139|        MOVE-CORRESPONDING ls_abort_here TO tt_pat01.                                       |

|  140|      ELSE.                                                                                 |

|  141|        tt_pat01-stepcond = gc_step_finished.     "Step finished                            |

|  142|        MOVE-CORRESPONDING ls_abort_here TO tt_pat01.                                       |

|  143|      ENDIF.                                                                                |

|  144|                                                                                            |

|  145|*     Now update the queue.                                                                 |

|  146|      MODIFY tt_pat01.                                                                      |

|  147|      CALL FUNCTION 'SPAM_UPDATE_STATUS'                                                    |

----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------

|Contents of system fields                                                                         |

----------------------------------------------------------------------------------------------------

|Name    |Val.                                                                                     |

----------------------------------------------------------------------------------------------------

|SY-SUBRC|0                                                                                        |

|SY-INDEX|0                                                                                        |

|SY-TABIX|67                                                                                       |

|SY-DBCNT|2                                                                                        |

|SY-FDPOS|40                                                                                       |

|SY-LSIND|0                                                                                        |

|SY-PAGNO|0                                                                                        |

|SY-LINNO|1                                                                                        |

|SY-COLNO|1                                                                                        |

|SY-PFKEY|0100                                                                                     |

|SY-UCOMM|IMPL                                                                                     |

|SY-TITLE|Support Package Manager - Version 7.00/0049                                              |

|SY-MSGTY|S                                                                                        |

|SY-MSGID|OO                                                                                       |

|SY-MSGNO|003                                                                                      |

|SY-MSGV1|Object type                                                                              |

|SY-MSGV2|CX_HRPADNO_ACF_SYSTEM_FAULT                                                              |

|SY-MSGV3|                                                                                         |

|SY-MSGV4|                                                                                         |

|SY-MODNO|0                                                                                        |

|SY-DATUM|20130518                                                                                 |

|SY-UZEIT|000609                                                                                   |

|SY-XPROG|SAPLSCSMROUTE                                                                            |

|SY-XFORM|TRINT_TP_UPDATE_TPSTAT                                                                   |

----------------------------------------------------------------------------------------------------

Please help me with this.

Problems solved, in se80 to inactive objects has duplicate includes, manual activation solved my problem.

2 REPLIES 2
Read only

0 Likes
478

Hi,

I have exactly the same problem, can you tell me which are the objects you have activated, please !!!

Thanks

Read only

0 Likes
478

in se80 to inactive objects has duplicate Include LIMU REPS PCSUBRU0_CURRM_AVERA, manual activation solved my problem.