cancel
Showing results for 
Search instead for 
Did you mean: 

Query on Materials with deletion date

Former Member
0 Kudos

Dear All,

We need a query (SQ01/SQ02) with following result:

- Material with deletion flag

- Date of the deletion (when deletion flag was set)

and the following selection:

- Period of deletion

- Plant

I know that I can find the material with MARA (and MARA - LVORM for deleted material). How can I find the date when a material was deleted?

Thank you in advance for your inputs.

Best regards,

Thomas

Accepted Solutions (1)

Accepted Solutions (1)

JL23
Active Contributor
0 Kudos

you dont need to retrieve the dates from this perfomance cracker tables CDHDR/CDPOS.

Just pull it from table MSTA which keeps the administrative information of materail master.

Set a deletion flag, then check MSTA, to get knowledge about the structure and status of the record.

Answers (5)

Answers (5)

former_member192897
Active Contributor
0 Kudos

Material can be set flag for deletion on different levels for eg: Plant (MARC), Stor locn (MARD), and Client(MARA).

First you have to trace out the material which are set flag for Deletion.

Then Go to SE11 and input CDHDR table and Execute.

Now input Materials which are flagged for deletion and transaction Code MK06 in the Respective field and Execute.

Former Member
0 Kudos

Thank you for your replies.

As we need more information as we receive by using table CDHDR or program CHANGEDOCU_READ we have to do a query (or a report program, but as I'm not a ABAP-Developper this would be more difficult).

Is there no possibility to link MARA with CDHDR in SQ01/SQ02?

Thanks,

Thomas

Former Member
0 Kudos

Hello

Table CDHDR with:

OBJECTCLAS = 'MATERIAL'

OBJECTID = material number from MARA (with leading zeros)

TCODE = 'MM06'

CHANGE_IND = 'U'

and you will have UDATE and UTIME

Former Member
0 Kudos

Hi,

you check with CDHDR table,give transaction as MM06(Delete material) in selection screen . Object value is the material number.

then we can find the material deletion date and time and who deleted it....

Thanks

Raja

csaba_szommer
Active Contributor
0 Kudos

Hi,

DF for material can be set at different levels not only at client level - so, not only table MARA may contain information on deletion (e.g. you can set DF at warehouse, SLoc level, etc.).

Table CDHDR contains information on changes of material master.

Regards,

Csaba

Edited by: Csaba Szommer on Jan 20, 2009 8:36 AM

Former Member
0 Kudos

Dear Csaba,

Thank you for theses informations.

I tried to link MARA with CDHDR. But I cant link MATNR with OBJECTID.

How can I do this query?

An other problem is the performance when using CDHDR....

Thanks,

Thomas

Former Member
0 Kudos

you may try this :

go to SA38 , enter program name : CHANGEDOCU_READ , then execute , enter object class material , enter restriction period, then Tcode MM06, then execute

in the table key, you'll get the material number,there's date and time and user id then delete the material.