02-17-2015 10:53 AM
Hi,
I want to call an ABAP report "A" within another ABAP report "B".
With the report "A" I have created a batch-input (SHDB), and with this recorded batch-input I built a function module.
In report "B" I call this function module with CALL FUNCTION.
In our test system it works. Report "B" calls report "A", and when I test the function module with SE37, it works, too.
But when I want to run it in our productive system, I always get the subrc 1001.
I have found the following info:
Mode "N": Processing without display of screens. If a breakpoint is reached in one of the called transactions, processing is terminated with sy-subrc same as 1001. The field sy-msgty contains "S", sy-msgid contains "00", sy-msgno contains "344", sy-msgv1 contains "SAPMSSY3", and sy-msgv2 contains "0131".
But there are no breakpoints in my program.
I do not understand this behavior. Why does the program works in the test-system and breaks in the productive system?
Kind regards
Oliver
02-17-2015 1:40 PM
Hi Oliver,
Also check in foreground by changing the mode 'A' in debugger. This is not due to difference in system. It may be due to difference in value which we are passing.
In some case the error occurs if the value is not matching with the field. In foreground, you can easily find out.
Eg: For employee number instead of giving 8 digit number, user may given characters, on such case, this will occur.
Regards
Rajkumar Narasimman
02-17-2015 1:33 PM
It's beacuse your OKCODE statement is incorrect, or missing, i think. Use this BDC_OKCODE (=FNAM).
02-17-2015 1:40 PM
Hi Oliver,
Also check in foreground by changing the mode 'A' in debugger. This is not due to difference in system. It may be due to difference in value which we are passing.
In some case the error occurs if the value is not matching with the field. In foreground, you can easily find out.
Eg: For employee number instead of giving 8 digit number, user may given characters, on such case, this will occur.
Regards
Rajkumar Narasimman
02-17-2015 2:55 PM
Hi Rajkumar,
you are great. The mode "A" was the solution.
I have found an error in my batch-input.
Thank you for the help.
Kind regards
Oliver