Retrieving data from MCDOK table

79 views Asked by At

I am quite in new SAP database queries and I need somebody to explain, how to achieve the following result:

Problem:

  1. I must find all documents of type PRT with attachment PDF (created via CV01N)
  2. Those attachments have descriptions, of which some could have a description like "ISSUE123" or could be simply empty. The description field is from table MCDOK, the field is MCDOK-FILE_DESCRIPTION (standard view CV03N > Originals > Details of attachment).
  3. I want to retrieve all attachments with description "ISSUE123" or empty

Currently I do not know how to retrieve data from the table MCDOK. In SQVI no JOIN operations are possible. In SE16N it is not possible to open MCDOK directly.

I am learning SAP Query by doing. It would be very helpful if somebody could help me to build a quick solution or direct me into the right direction.

1

There are 1 answers

0
Philipp On

The database table with all the documents appears to be the table DRAW.

Even though I never used that transaction before, I was able to find that out by:

  1. Running the transaction
  2. Putting the cursor in the first field of the selection screen ("Document")
  3. Pressing F1 to open the help window for that field
  4. Clicking on the "technical information" button in the button bar of the help window
  5. Looking at the table name and noticing that it is a "transparent table" (read, database table).

The description texts for documents, though, appear to be in the table DRAT. I found that by opening a random document and doing the same process with the description field. Note that a document can have different descriptions depending on the language. So for each entry in table DRAW there can be any number of entries in table DRAT.