Skip to Content

Storing data temporally in Application server :ABAP

I am working in ECC EHP6.6.
I am facing one technical challenge.

I have loop consisting of primary key (BKPF: BUKRS, BELNR, GJAHR)

Inside loop other data is fetched from various tables via class methods. (like BSEG, BSET, etc.) and Reference # (XBLNR) and saved to one database table after some checks.The fetched data is for each line of the loop. So after each run of the loop there will be one

My requirement is to compare no. of lines of BSEG and Reference no. XBLNR of different lines of the loop.

I can enhance (implicit) a class method where the Reference # (XBLNR) is fetched and updated. But I can not change the program, the program is not modifiable or can not be enhanced.

So, is there any way I can store the BKPF-XBLNR, and BSEG no. of lines with primary keys. And access it inside the method which is inside the loop to compare and update XBLNR.

Basically, Is there a way of storing data in application server which can be accessed in different scopes of a program. The data will be in the form of a internal table and should not be effected by loop iterations.

I thought of two things, but I can't use them. Please suggest if anything else is there.
1. Creating a database table to storing the data temporally and deleting it after last record.
2. Creating a global class, and using a static internal table to store the data.

Sorry for the big question, Please suggest any other alternates.


Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Apr 10, 2018 at 12:04 PM
    Add comment
    10|10000 characters needed characters exceeded