cancel
Showing results for 
Search instead for 
Did you mean: 

Deletion of all PSA data, older than xx days

Former Member
0 Kudos

Dear all,

is it possible to delete the data of all(!) exisiting PSA tables, which are older than xx days. When I use the standard functionality in RSA1, it is only possible to schedule a job for only one (and not all) PSA entries - even when I use the standard function on the top node of the PSA hierarchy?!?

Thanks,

Andreas

Accepted Solutions (1)

Accepted Solutions (1)

GFV
Active Contributor
0 Kudos

Hi Andreas,

as per my knowledge it's not possible such a scheduling option ... That should be because of the fact that with the same procedure you can delete even Change Log Data (from ODSs), corrupting, as a consequence, Delta Mechanism of Data Mart Interface.

Some times ago this topic have been discussed: take a minute to search for such a discussion

Hope it helps

GFV

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi,

I encountered the same problem and made process chain with a variant, that is filled with all possible PSA tables by a custom made program. Here's the code that works for BW 3.5. If it still works in BI you have to try yourself.

&----


*& Report ZAGENTMULDER PSADELETE

*&

&----


*Short text

*

  • Fill table of process chain DEL_PSA variant DEL_PSA

*

*Purpose

*

  • This program fills the table of PSA to be deleted in chain

*

*Integration

*

  • The program checks that it is not run in the production environment by

  • verifying that the system id does not starts with a 'P'.

*

*Prerequisites

*

  • If that variant does not exist make it using RSPC > process types >

  • other BW processes > Deletion of requests from PSA or change the

  • selection option from DEL_PSA into an existing variant (use the tecnical

  • name). The other settings like 'Older than' are not changed by the

  • program.

*

*Features

*

  • Note that the select function in the chain variant (RSPC) does not list

  • inactive transfer rules. In this program however these are selected as

  • well. After the program run, open the variant (RSPC). A pop-up will tell

  • you all inactive structures are removed. Confirm the pop-up and save the

  • variant. Now you can run the chain with the variant.

*

*Selection

*

  • Default value for variant: DEL_PSA.

REPORT ZZBWTOOLS_PSA_DELETE.

tables:

RSPCVARIANT,

RSTSODS,

RSISOSMAP.

check not syst-sysid(1) eq 'P'.

data:

he_lnr like RSPCVARIANT-LNR.

parameters:

VARIANT like RSPCVARIANT-VARIANTE default 'DEL_PSA'.

DELETE from RSPCVARIANT WHERE

TYPE = 'PSADELETE' AND

VARIANTE = VARIANT AND

OBJVERS = 'A' AND

FNAM = 'PSATABLE'.

clear he_lnr.

select * from RSPCVARIANT where

TYPE = 'PSADELETE' AND

VARIANTE = VARIANT AND

OBJVERS = 'A'.

if RSPCVARIANT-LNR gt he_lnr.

move RSPCVARIANT-LNR to he_lnr.

endif.

endselect.

move:

'PSADELETE' to RSPCVARIANT-TYPE,

VARIANT to RSPCVARIANT-VARIANTE,

'A' to RSPCVARIANT-OBJVERS,

'PSATABLE' to RSPCVARIANT-FNAM,

'I' to RSPCVARIANT-SIGN,

'BT' to RSPCVARIANT-OPT.

select * from RSTSODS.

move RSTSODS-ODSNAME to RSPCVARIANT-LOW.

select single * from RSISOSMAP where

TRANSTRU eq RSTSODS-ODSNAME and

OBJVERS eq RSTSODS-OBJSTAT(1).

check sy-subrc eq 0.

move:

RSISOSMAP-ISOURCE to RSPCVARIANT-HIGH,

RSISOSMAP-LOGSYS to RSPCVARIANT-HIGH+30.

add 1 to he_lnr.

move he_lnr to RSPCVARIANT-LNR.

insert RSPCVARIANT.

endselect.

former_member192700
Active Contributor
0 Kudos

Hi Andreas,

this is actually not possible in the current release. It will be included as a standard functionality in one of the next releases. Workarounds have already been described by our peers aforementioned.

Cheers

Andreas

Former Member
0 Kudos

Hi Andreas,

you can add a process type to a process chain that will allow you to delete selected psa tables. This may fit to your requirement. So no immediate deletion of all, but of selected tables at a time.

regards

Siggi

Former Member
0 Kudos

Hi,

Use the process type (Deletion of Requests from PSA )..start the process chain and include this process type and select the PSA data and give XX days...

It might solve your problem..If yes give me points