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

Problems with calling batch input inside a report

Daniel_Degenhardt
Product and Topic Expert
Product and Topic Expert
0 Likes
1,373

Hi experts, I have the requirement to change the billing plan related to the customer contract (VA42). I tried multiple ways to change the billing plan rule (marked in the screenshot) field name is "FPLA-PERIO". But somehow none of these approaches worked. For example:

https://answers.sap.com/questions/1522483/bapi-or-function-to-update-billing-plan-in-sales-o.html

The system provides no error when executing the function module. But it also doesn't change the billing plan.

My approach was that I recorded a batch input (BDC) which changes the billing plan rule. Based on this batch ipunt I created a function module.

Problem: My idea is to integrate this function module in my report. For example, if I call the function module in a report which has no additional selection screen everything works fine and the module changes the billing period.

But I want to use the function module in a report which has an initial selection screen. I think this causes the problem that the function module doesn't work inside this "other" report. I assume that there is a dynpro error. I'm receiving the Error 1001.

So what would help me?

Do you think that my assumption regarding the error is right?

If yes why does this happen?

Is it possible to fix this Issue in any way?

Alternatively: Do you know the right combination of function modules to change the billing period so that I do not need to use the batch input?

3 REPLIES 3
Read only

r010101010
Active Participant
1,217

Hi Daniel,

I think you can analyse the error in more detail and identify the issue :

1) check the error in the return table, you will know on which element the error is

2) run the BDC in foreground by changing the mode to A

Read only

Daniel_Degenhardt
Product and Topic Expert
Product and Topic Expert
0 Likes
1,217

Hi Deenesh, thanks you're right.

Mode "A" helped me to find the issue.

The Problem is that: Before the batch starts I'm modifying the contract with a BAPI. which leads to a locked contract by the BAPI which can't access by the batch Input.

Thanks 🙂

Read only

1,217

Hello Daniel,

is this your question still not answered or has been solved? because you have written as answered and not comment. So if BAPI has locked contract and you can not access it by batch input. you can try to DEQUEUE_ ... or after using BAPI, WAIT UP TO 5 SECONDS. then you can use Batch input.