cancel
Showing results for 
Search instead for 
Did you mean: 

Production Order Archiving

Former Member
0 Kudos

Hi All,

I'm starting a project to archive old production orders. I have seen many other posts with step-by-step guides in the forums here, but I am stuck with one of the first steps... I think. I tried going to SA38 and running program PPARCHA1 to do the write, and when I execute this I receive the message that "No order corresponds to selection criteria." I left the criteria wide open... and it does not recognize any production orders to archive. I have tried running SARA as well for object PP_ORDER as well, and no matter what I put as the variant criteria, nothing is written.

I know there are old TECO orders in the system... am I missing something I must do before archiving?

Thanks,

J

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi J,

In addition to what Prasobh and Prasad suggested, i would also suggest the following:

- First step is to set the deletion flag and deletion indicator, but before you do that, please check whether proper residence times have been setup according to your requirements

- When setting the deletion flags and deletion indicators, it will check whether it satisfies the residence time and also performs some checks

- for more information on residence time and checks, please refer to http://help.sap.com/saphelp_47x200/helpdata/en/5c/c4963457889b37e10000009b38f83b/frameset.htm

I would recommend using transaction SARA to run the pre-processing, write and delete runs than SE38/SA38.

hope this helps,

Naveen

Former Member
0 Kudos

Hi,

Step 1: Tcode OPJH u201CMAINTAIN PRODUCTION ORDER TYPEu201D

Make sure Residence Time 1 and Residence Time 2 are blank.

Step 2: Tcode SE38:ABAP Editor

First we need to set the Deletion Flag in the Order, to do so use the Program u201CPPARCHP1u201D and execute.Enter the Order details as shown Below

Oder

Order Type

Plant

Also First Tick on u201CSet deletion Flagu201D Radio Button and to test select u201CTest Modeu201D in u201CProcessing Optionu201D

If the test mode is successful it will give the following message.

Then change the u201CProcessing Optionu201D to Production Mode and execute, You will get the message "DELETION FLAG ACTIVATED FOR ORDERS".

Then Check the production Order, the status will be set to u201CDLFLu201D. This can also be done directly in the production Order Directly by setting the deletion flag.

Step 3: Tcode SE38:ABAP Editor

Next we need to set the Deletion Indicator in the Order, to do so use the same Program u201CPPARCHP1u201D and execute as shown below.

Enter the Order details as shown Below

Oder

Order Type

Plant

Also First Tick on u201CSet deletion Indicatoru201D Radio Button and to test select u201CTest Modeu201D in u201CProcessing Optionu201D.

change the u201CProcessing Optionu201D to Production Mode as shown below and execute.

You will get the message "DELETION INDICATOR ACTIVATED FOR ORDERS".Then Check the production Order, the status will be set to u201CDLT".

Step 4: Tcode SE38:ABAP Editor

Next we need to Archive the Order, to do so use the same Program u201CPPARCHA1u201D and execute as shown below.

Enter the Order details as shown Below

Oder

Order Type

Plant

To test select u201CTest Modeu201D in u201CProcessing Optionu201D.

If archiving is possible you will get the message.

Change the u201CProcessing Optionu201D to Production Mode and execute.

Step 5: T Code CO78

Click on u201CDeleteu201D Button.

Then Press on Archive selection:

Select the file to be archived.

Archive selection becomes green and then select the Start Date Button.

Press on u201CImmediatelyu201D and then save.

Start Button becomes green and then press on Spool Parameter Button.

Choose Output device as LP01 and then save. You will get a formatting message, click OK and then continue.

You will see the spool parameter turns green, then Press on execute button.

You will get the message New deletion jobs where scheduled, click on u201COKu201D.

This ensures the production order is deleted from the system.

Step 6: Tcode OPJH u201CMAINTAIN PRODUCTION ORDER TYPEu201D

Make sure Residence Time 1 and Residence Time 2 is restored to original status.

Regards

Vinod

Edited by: Vinod Mohan on May 7, 2009 8:07 AM

Edited by: Vinod Mohan on Jun 11, 2009 10:14 AM

former_member196398
Active Contributor
0 Kudos

Naveen,

In most of the projects, generally nobody would have access to SE38/SA38 in Production system, so that may not be possible in actual scenario,

Can you please explain why your are recommending "SARA"?

Regards,

Prasobh

Former Member
0 Kudos

Hi Prasobh,

You are right with the statement "In most of the projects, generally nobody would have access to SE38/SA38 in Production system, so that may not be possible in actual scenario, "; thats the reason i suggested SARA instead of SE38/SA38.

For the question why SARA is recommended for archiving, please refer to note 133707. It is not that one cant run archiving using SE38/SA38, but its always recommended to use SARA as it has a lot of advantages on the long run.

Thanks,

Naveen

Former Member
0 Kudos

Thanks for the replies.

The problem was that the deletion flag/deletion indicator was not being set because of the residence time settings. I changed the settings from 1 to blank, and the orders are now accepting the deletion flags and show up in PPARCHA1.

former_member196398
Active Contributor
0 Kudos

Naveen,

Thanks for sharing the information on SARA.

SAP recommendation of archiving process through SARA was till 4.6B, because of various contraints in the file naming etc... now I think already the have fixed all the problems which was encountered till that version from 4.6C onwards.

Anway it was a good information you have shared to the forum.

Regards,

Prasobh

Former Member
0 Kudos

How do you change the residence time?

Where do you change it?

Edited by: Justin on Jun 11, 2009 5:33 AM

Former Member
0 Kudos

Hi,

You change the Residence time in TCode OPJH u201CMAINTAIN PRODUCTION ORDER TYPEu201D .

Regards

Vinod

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

After Done the TECO

1. Settle the production order

2.Close the production order

3. Set the deletion flag

4. Set Deletion indicator

By setting these status definately you can archive the object

Former Member
0 Kudos

hi,

For Production Order Archiving,

1. You need to settle the Production Orders.

2. Set the Deletion Flag (DLFL)

3. Set the Deletion Indicator (DLT)

Then Deletion and Archiving can be done.

Of all, the Most important stpe is the setting of DLFL.

There are number of dependencies for the DLFL .

1. There should not be any costs on the Order

2. Order Status and Operatiuon status should be CNF.

3. There should not be any entries in the COGI or COFC with reference to these Orders.

4. Threre should not be any Open PurReq or Pur. Ordes.

Now follow the procedre below:

1. First Execute the program : PPARCHP1 with Deletion Flag Activated and the selection should be all your Prod. Orders

or you can have a selection criteria to do that.

After this some of the orders will not get the DLFL Flag, there can be numbr of reasons for that.

2. Execute the same program PPARCHP1 with Dletion Indicator activated.

Now you got the DLFL and DLT both for your Production Orders.

Residence Time 1 & Residence Time 2 will play a major role on this.

If both are maintained as 1 & 1 then the Prod. Orders should reside in the system with DLFL for 1month.

after that only you can put the DLT. and also after putting DLT you need to wait for 1month for Deletion or achiving.

3. Now goto PPARCHA1 (Archiving) and execute the Program with your same selection criteria.

Here your Basis peoples role is imporatant for setting the File Path for Archive directory for the Object : PP_Order.

4. Now use the T. Code CO78 or T. code SARA (with PP_Order as object Name) for deletion of Orders.

Execute the programs in the Foreground, so that you will come to know waht was the problem if ny.

You can excute th background program run for Deletion.

Regards

Ramesh

former_member335796
Active Contributor
0 Kudos

Hi Ramesh,

How are you doing?

It will be better to paste the link than the answer..

Regards,

Siva

former_member196398
Active Contributor
0 Kudos

Chanski,

Before you are trying Archiving run, you need to set the Deletion Flag and Deletion Indicator for the order.

Generally we schedule the following programs in background in the sequence below,

1. PPARCHP1 for Setting Deletion Flag

2. PPARCHP1 for Setting Deletion Indicator (Once set cannot be revoked- so care should be taken in selection of orders)

3. PPARCHA1 for archiving the production order with Deletion Indicator active. Basis should set the database/storage space for archiving/storing the records.

4. PPARCHD1 for Deleting the records from SAP database.

Regards,

Prasobh

Former Member
0 Kudos

Dear,

Go to SE38 and run the programs mentioned by Prasobh and in the initial screen give one or two production orders for testing. Please revert back if any further clarifications required.

Regards,

Prasad