cancel
Showing results for 
Search instead for 
Did you mean: 

Recognize last package in start routine

Former Member
0 Kudos

Hello,

i am writing a start routine in the transformation to an DSO.

I want to built an internal table with all keys of the whole request, not only of a single package.

In the last package I want to loop through this table.

Question: Is it possible to recognize in a start-routine that this is the last package ??

Thanks

Armin

Accepted Solutions (1)

Accepted Solutions (1)

former_member192700
Active Contributor
0 Kudos

Hi Armin,

Your question is basically 2-folded:

1.) How can I determine the last data package of a request?

==> Starting with SPS19, you will be able to determine it via a method call. Please see SAP note #1231211, which will be released when SPS19 is released.

2.) How can I process all records (spanning multiple data packages) of a request?

==> you cannot, since the system is calling the Transformations (and thus also the ABAP routines) for every single data package with a new mode, hence your anticipated internal table would be deleted on the second, third, etc. call. The only option is to tailor the data package size for the data at hand to a single data package. You can either do so by increasing the data package size or reducing the processed number of records by applying filters in the DTP or selections in the InfoPackage.

Cheers

SAP NetWeaver BI Organisation

Former Member
0 Kudos

Hi Andreas,

you are right, there are two problems.

The first one should be solved.

The second one (spanning multiple data packages) should not be so difficult.

As I am informed (I did not realy test it yet) you can use the "Global-Area" in a start-routine for declaring datas that are stored over the whole request, by using class-Data:

Thanks Armin

Former Member
0 Kudos

Hello,

I marked this Question as answered, but today it does not help me.

==> Starting with SPS19, you will be able to determine it via a method call. Please see SAP note #1231211, which will be released when SPS19 is released.

I did not find the SAP-note.

Is there any solution that runs today ?

I have tried with table RSTSODSREQUESTPG, but unfortunately I did not find an entry in this table with my Requestnumber.

Thanks

Armin

0 Kudos

Hi

To the Point 2:

Another, and for me better possibility is to set DTP / InfoPackage for serial processing. In this case all datapackages will be processed in the same task, serially. In this case all global data (those declared in global part of the BW-routines or in Top-Includes of any function modules called from BW-routines) are visible across all datapackages.

For me this way is nicer and safer, because totally independent of the (future) size of datapackage (Example: you set max number of records in datapackage to 1000, because you expect no more than this, but in the future it may happen that this limit will be exceeded at the source, and this would lead to split in more than only one datapackage, and to failure of the whole logic). From the performance perspective its the same (one datapackage means also "serial" processing) or under circumstances maybe something better (when some logic makes an exhausting DB-selections in "for all entries.." manner or so, more datapackages can be a positive thing).

Regards!

Tomasz

Answers (1)

Answers (1)

former_member192700
Active Contributor
0 Kudos

Hi Armin,

Sorry, as stated above, no.

Cheers

SAP NetWeaver BI Organisation