cancel
Showing results for 
Search instead for 
Did you mean: 

Error :Update was terminated- PM Notification

0 Kudos

Hi,

While creating PM notifications either directly or while during background job scheduling , sometimes system throws error "Update terminated" and its unable to save notification.

Notification configuration includes early number allocation and buffer 10.

Its able to create notification after some time  . Request expert advice on how I could get rid of these errors.?

I have gone through related posts. But its not clear why the system is showing error related to number range ?

Accepted Solutions (1)

Accepted Solutions (1)

peter_atkin
Active Contributor
0 Kudos

Roshini

Does this happen when large volumes of notifications are being created?

PeteA

0 Kudos

Hi Pete,

This issue is happening both with large volumes (while background scheduling IP10) as well as for individual notification creations(IW21) at random times.

Regards,

Roshini

peter_atkin
Active Contributor
0 Kudos

Roshini

,

You could try raising the buffer level (SNRO) - but read this OSS Note first which has some useful info: http://service.sap.com/sap/support/notes/1398444

Alternatively, it could be caused by one of your developments causing a COMMIT issue.

Can you post the ST22 log??

PeteA

0 Kudos

Hi,

Please find the error log below.

Category               ABAP Programming Error
Runtime Errors         SAPSQL_ARRAY_INSERT_DUPREC
Except.                CX_SY_OPEN_SQL_DB
ABAP Program           SAPLBOQM
Application Component  CA
Date and Time          06.01.2015 16:09:16
----------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------
|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 "SAPLBOQM" 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 "OBJECT_NUMBER_INSERT_QM" "(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"                                              |
|    "SAPLBOQM" or "LBOQMU02"                                                                      |
|    "OBJECT_NUMBER_INSERT_QM"  

Regards,

Roshini

paul_meehan
Advisor
Advisor
0 Kudos

Hi,

The relevant part of the dump would be the code section where there will be an 'insert' statement. That will indicate which table is causing the problem.

As dump occurs in OBJECT_NUMBER_INSERT_QM the table must be ONR00 or ONRQM. The report RBONRRP1 may help fix any inconsistencies on these tables - run for object type QM.

-Paul

0 Kudos

The object number isQM000010003105. However, the largest object number in
ONR00 is QM000010054464. On the other side, in SNRO the number range object QMEL_NR,  current number in number range setting is:
01 000010000000 000099999999 10003229    <<-------

The current number is far away less than the largest entry in ONR00.

0 Kudos

Currently maintenance orders are also resulting in short dump in FM CO_VB_ORDER_POST

 

Source Code Extract                                                                               |

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

|Line |SourceCde                                                                                   |

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

|    8|            MOVE-CORRESPONDING caufv_tmp TO afko_kal_i. " For Calendar at MWO Header        |

|    9|            APPEND afko_kal_i.                                                              |

|   10|                                                                                            |

|   11|ENDENHANCEMENT.                                                                             |

|   12|ENHANCEMENT 3  .                                                                            |

|   13|*                                                                                           |

|   14|            MOVE-CORRESPONDING caufv_tmp TO afko_kal_d. " For Calendar at MWO Header        |

|   15|            APPEND afko_kal_d.                                                              |

|   16|ENDENHANCEMENT.                                                                             |

|   17|ENHANCEMENT 4  .                                                                            |

|   18|*                                                                                           |

|   19|*--------------------- For Calendar at MWO Hearder -----------------------------            |

|   20|*--------------------------------------------------------------------*                      |

|   21|*..Verbuchungstabellen der AFKO_KAL abarbeiten                                              |

|   22|*..Zuerst Loeschen wegen DUPREC-Gefahr                                                      |

|   23|                                                                                            |

|   24|*..AFKO_KAL loeschen                                                                        |

|   25|  DESCRIBE TABLE afko_kal_d LINES entries.                                                  |

|   26|  IF entries > 0.                                                                           |

|   27|    DELETE afko_kal FROM TABLE afko_kal_d.                                                  |

|   28|*..erfolgreich ?                                                                            |

|   29|    IF sy-subrc EQ 4.                                                                       |

|   30|      clear sy-subrc. "Delete only if the record exists.                                    |

|   31|    ENDIF.                                                                                  |

|   32|  ENDIF.                                                                                    |

|   33|  FREE afko_kal_d.                                                                          |

|   34|                                                                                            |

|   35|*..AFKO_KAL inserten                                                                        |

|   36|  DESCRIBE TABLE afko_kal_i LINES entries.                                                  |

|   37|  IF entries > 0.                                                                           |

|>>>>>|    INSERT afko_kal FROM TABLE afko_kal_i.                                                  |

|   39|*..erfolgreich ?                                                                            |

|   40|    IF sy-subrc EQ 4.                                                                       |

|   41|      DESCRIBE TABLE afko_kal_i LINES entries.                                              |

|   42|      MESSAGE a804 WITH 'AFKO_KAL' entries sy-dbcnt.                                        |

|   43|    ENDIF.                                                                                  |

|   44|  ENDIF.                                                                                    |

|   45|  FREE afko_kal_i.                                                                          |

|   46|                                                                                            |

|   47|*..AFKO_KAL updaten                                                                         |

|   48|  DESCRIBE TABLE afko_kal_u LINES entries.                                                  |

|   49|  IF entries > 0.                                                                           |

|   50|    MODIFY afko_kal FROM TABLE afko_kal_u.                                                  |

|   51|*..erfolgreich ?                                                                            |

|   52|    IF sy-subrc EQ 4.                                                                       |

|   53|      DESCRIBE TABLE afko_kal_u LINES entries.                                              |

|   54|      MESSAGE a805 WITH 'AFKO_KAL' entries sy-dbcnt.                                        |

|   55|    ENDIF.                                                                                  |

|   56|  ENDIF.                                                                                    |

|   57|  FREE afko_kal_u.                                                                          |

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

peter_atkin
Active Contributor
0 Kudos

This sounds more like a general system issue.

Talk to you Bassi Team to see if they can find any common problems,

PeteA

0 Kudos

Basis team has confirmed that the issue is not related to Basis. Please guide.

MTerence
Active Contributor
0 Kudos

Hi Roshini,

If you are able to reproduce the issue, you can raise a OSS to SAP.

Regards

Terence

paul_meehan
Advisor
Advisor
0 Kudos

Hi,

For the notification issue you may have multiple ranges. That may explain why highest ONR00 is QM000010054464. If you only have a single range then ensure the current number is change so it is higher than 10054464.

If you have multiple ranges then check there is sufficient space for growth between 'current number' and 'lowest' number already existing in QMEL for that range.

Do run the  report RBONRRP1 to check for any inconsistencies in ONR00 or ONRQM.

-Paul

paul_meehan
Advisor
Advisor
0 Kudos

Hi,

Also check the order number range AUFTRAG via SNRO. Here there may be multiple ranges. So check the current number has space to expand. Use table AFIH to see what order numbers are already used.

It looks like number ranges may have been transported from another system/client?? Possibly now inconsistent with the existing orders/notifications. Only option is to adjust the current number so space is available for growth.

Because of buffering, when you reset the current number you must flush the already buffered numbers. See the information in note 741698.

-Paul


0 Kudos

Notification number range issue is solved by updating current number range  status as 10054464. Order creation is having issues now. Created orders are not getting saved in table. System generates update error after displaying order number from IW31. using IP10 also system is unable to generate orders

paul_meehan
Advisor
Advisor
0 Kudos

See my answer above about fixing the order number range (AUFTRAG)

0 Kudos

4002822 - Table AFIH

4002939 - Tcode OION

Number range interval -      4000000    --          4999999

0 Kudos

Also we have a single number range for all maintenance notifications. Similiarly a single no range for all maintenance orders

paul_meehan
Advisor
Advisor
0 Kudos

Hi,

It may help to check what values exist in AFKO_KAL. Maybe then adjust current number to avoid any existing values in this table.

-Paul

0 Kudos

4054464 is the current no in table AFKO_KAL

paul_meehan
Advisor
Advisor
0 Kudos

That number (4054464) is higher than the current number from number range 4002939. Can you adjust the current number to be higher than this.


0 Kudos

ok. ie' update number status in OION to 4054464?

paul_meehan
Advisor
Advisor
0 Kudos

I would usually push the number up a bit so it is clear where the new range started - maybe 4054500


0 Kudos

Done . Now system is behaving fine. Thank you Paul Meehan. I would like to know why there was a huge difference in these table entries. Is it because the early no allocation is activated and since the users have used up many notification numbers without saving notification.?

paul_meehan
Advisor
Advisor
0 Kudos

Good to hear it is sorted.

The buffering will always result in gaps between the numbers and creating a document without saving will also contribute to the gaps. However there should not be a disconnect between the current number and the actual data in the tables. Not clear why that happened in this case.

-Paul


Answers (1)

Answers (1)

0 Kudos

Hello Roshini,

It seems a no. range issue to me kindly goto number range configuration and try to create a new group and save, if you cannot find the newly created number range/group then it is an number range inconsistency problem.

Go to SE38 and run program RSSNR0T1 with object DNO_NOTIF then execute and click on establish consistency.

This will resolve the error.

Regards,

Shivkumar Tiwari

0 Kudos

Hi  Shivkumar,

I would like to bring it to your notice that the number range object which I have used is QMEL_NR. Number ranges are currently not mapped against object DNO_NOTIF.

Regards,

Roshini Razack

0 Kudos

Hi Roshini,

Perform the above steps with object type QMEL_NR.

0 Kudos

Hi Shivkumar,

On executing the program the system displayed message that there are no inconsistencies for object QMEL_NR.

We experience similiar issues for other objects EINKBELEG –Purchase order,BANF - Purchase requisition as well.


Regards,

Roshini Razack