10-06-2005 11:16 AM
Hello all,
Please tell me what function or method to use to assign a document to a material. A inconvient solution for me is using BDC data in trans. MM02.
Your helpful answer will be rewarded.
Thank you!
Bogdan
10-06-2005 11:47 AM
Hi Bogdan,
Can you be more specific? What you mean by document?
Cheers
Vinod
10-06-2005 11:58 AM
Hi Vinod,
By document i meant linked document. You can look on transction MM03 or MM02->Additional Data->Document Data.
Thank you
Bogdan
10-06-2005 12:33 PM
Hi Bogdan,
You can use BAPI_DOCUMENT_SAVEOBJECTLINKS.
You will have to fill the table BAPI_DOC_DRAD.
Object Type will be "MARA" , Object key will be material number . See table DRAD for refernce .
With this BAPI you can link one document to many materials in one call . If you have more that one Document you will have to call again,
Cheers.
10-06-2005 1:32 PM
Hi Sinha,
Your solution seems to be the right one, but is not working. Do you have an ideea why? here are the some test value:
DOCUMENTTYPE Z01
DOCUMENTNUMBER E0100
DOCUMENTPART 000
DOCUMENTVERSION 00
OBJECTLINKS ( 1 record 😞
D OBJECTTYPE OBJECTKEY
MARA 000000000950700189
the others fields are empty.
Thank you a lot!
Bogdan