Написал программку которая делает массовый создание заказов и исходящих поставок для розницы. Делалось с использованием двух бапишек: BAPI_SALESORDER_CREATEFROMDAT2 и BAPI_OUTB_DELIVERY_CREATE_SLS, а также немножко bach-input. При обработке небольшого количества записей все было хорошо. Но когда запустил обработку на 5700 записей через какое то время вывылился дамп.
Краткий текст
Code:
Time limit exceeded.
Что произошло?
The program "SAPLFM23" has exceeded the maximum permitted runtime without
interruption and has therefore been terminated.
Что Вы можете сделать?
Code:
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.
Анализ ошибки
Code:
After a specific time, the program is terminated to make the work area
available to other users who may be waiting.
This is to prevent a work area being blocked unnecessarily long by, for
example:
- Endless loops (DO, WHILE, ...),
- Database accesses with a large result set
- Database accesses without a suitable index (full table scan)
The maximum runtime of a program is limited by the system profile
parameter "rdisp/max_wprun_time". The current setting is 1800 seconds. If this
time limit is
exceeded, the system attempts to cancel any running SQL statement or
signals the ABAP processor to stop the running program. Then the system
waits another 60 seconds maximum. If the program is then still active,
the work process is restarted.
Указания по устранению ошибки
Code:
Programs with long runtime should generally be started as background
jobs. If this is not possible, you can increase the system profile
parameter "rdisp/max_wprun_time".
Depending on the cause of the error, you may have to take one of the
following measures:
- Endless loop: Correct program;
- Dataset resulting from database access is too large:
Instead of "SELECT * ... ENDSELECT", use "SELECT * INTO internal table
(for example);
- Database has unsuitable index: Check index generation.
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:
"TIME_OUT" " "
"SAPLFM23" or "LFM23U04"
"FM23_GET_AVAILABILITY"
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.
Системная среда
Code:
SAP-Release 700
Application server... "erpdev"
Network address...... "172.30.2.34"
Operating system..... "AIX"
Release.............. "6.1"
Hardware type........ "0009B4CAD400"
Character length.... 16 Bits
Pointer length....... 64 Bits
Work process number.. 2
Shortdump setting.... "full"
Database server... "erpdev"
Database type..... "DB6"
Database name..... "TED"
Database user ID.. "SAPTED"
Char.set.... "C"
SAP kernel....... 700
created (date)... "Aug 12 2010 00:49:07"
create on........ "AIX 2 5 005DD9CD4C00"
Database version. "DB6_81 "
Patch level. 267
Patch text.. " "
Database............. "DB6 08.02.*, DB6 09.*"
SAP database version. 700
Operating system..... "AIX 1 5, AIX 2 5, AIX 3 5, AIX 1 6, AIX 1 7"
Информация о месте прерывания
Code:
Termination occurred in the ABAP program "SAPLFM23" - in
"FM23_GET_AVAILABILITY".
The main program was "ZAZS ".
In the source code you have the termination point in line 50
of the (Include) program "LFM23U04".
Фрагмент исходного текста программы
Code:
Строк ИсхднТкст
20 * Check if BCS Budgeting is active
21 STATICS: sl_ref_bcs_active TYPE REF TO if_ex_fmavc_bcs_active.
22
23 IF sl_ref_bcs_active IS INITIAL.
24 CALL METHOD cl_exithandler=>get_instance
25 CHANGING
26 instance = sl_ref_bcs_active.
27 ENDIF.
28
29 IF NOT ( sl_ref_bcs_active IS INITIAL ).
30
31 IF I_BCS_GJAHR IS INITIAL.
32 l_bcs_gjahr = i_gjahr.
33 ELSE.
34 l_bcs_gjahr = I_BCS_GJAHR.
35 ENDIF.
36
37 CALL METHOD sl_ref_bcs_active->CHECK_BCS_ACTIVE
38 EXPORTING
39 I_FM_AREA = I_FIKRS
40 I_FISCYEAR = l_bcs_gjahr
41 IMPORTING
42 E_FLG_BCS_ACTIVE = l_bcs_active.
43 ENDIF.
44
45 SELECT SINGLE * FROM fm01tol INTO l_f_fm01tol
46 WHERE fikrs EQ i_fikrs
47 AND gjahr EQ i_gjahr
48 AND versn EQ '000'.
49
>>>>> e_non_ava_check = l_f_fm01tol-non_ava_check.
51 e_rev_ava_check = l_f_fm01tol-rev_ava_check. "nb
52 e_always_ava_check = l_f_fm01tol-always_ava_check. "bk
53
54 IF NOT sy-subrc IS INITIAL.
55 CLEAR e_non_ava_check.
56 CLEAR e_rev_ava_check. "nb
57 CLEAR e_always_ava_check. "bk
58 * with 4.70: if BCS Budgeting is active, the default value for
59 * AVC is deactive, there has to be a FM01TOL entry with AVC
60 * deactive 'OFF' to activate AVC
61 if not l_bcs_active is initial.
62 move 'X' to e_non_ava_check.
63 endif.
64 ENDIF.
65
66 ENDFUNCTION.
Как я понял программа вывалилась в дамп во время создания заказа на розницу. Вывалилась из за долго не ответа системы. Не знаю что делать подскажите пожалуйста. Или хотябы направление в какую сторону капать?