Application Development 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: 

Issue when the loading records are more than 40000 in SAP BPC

Former Member
0 Kudos

Hi All,

This question is related to BPC ABAP.

Let me explain the scenario first:
We are using the standard process chain(/CPMB/IMPORT) to load the records into the cubes. In one of the step(LOAD) of this process chain, we have set the package size as 40000.

So when the user tries to load more than 40000 records, system will take the records in chunks of size 40000. For example: if user tries to load 86000 records into the cube. system first take 40000 records first and then next 40000 and the remaining 6000 in the next.

So In our BADI, we need to show how many records the user is trying to load and the number of accepted records and the rejected records after the validations, like shown below:
***package summary****

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

Number of Total Records : ***********

Number of accepted records : ************

Number of rejected records : **************

So In our case, the log should be as follows

***package summary****

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

Number of Total Records : 86000

Number of accepted records : 86000

Number of rejected records : 0

But since system is taking this 86000 in 3 chunks, logs are showing only for the last chunk, for example

***package summary****

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

Number of Total Records : 6000

Number of accepted records : 6000

Number of rejected records : 0

I tried to use a private variables(for total,accepted,rejcted)in the logic, so when each chunk runs, those variable will be updated and will show the correct details at the end. But those variables are getting initiazed before each chunk runs.

Please provide your thoughts on how to handle this scenario....

Thanks,

Amaresh K

1 REPLY 1

Ulrich_Schmidt
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Amaresh,

can you assure that the three runs of the BADI are executed inside the same user session? Then you could use EXPORT TO MEMORY, e.g. like this:

- Use IMPORT FROM MEMORY to read "counter" from session memory. If this fails: we are the first step in a sequence, so initialize "counter" with 0.

- Increment "counter" with current number of records.

- Use EXPORT TO MEMORY to save the current value of "counter" for the next step.

If each of the different steps is running in a fresh user session, it will be more difficult...

Regards, Ulrich