‎2005 Dec 06 8:24 AM
Hi,
i'm looking for a BAPI to create Material with reference. I found BAPI_MATERIAL_SAVEDATA but didn't find a 'reference'-parameter.
As an alternative i could also use a BAPI that reads all the data you need for BAPI_MATERIAL_SAVEDATA from an existing material and then use this data to create a new material.
Unfortunately BAPI_MATERIAL_GETDETAIL does not provide the same fields.
Can anyone help me out.
regards
Steffen
‎2005 Dec 06 8:40 AM
Hi
Welcome to SDN.
Try BAPI_STANDARDMATERIAL_CREATE
REgards,
Abdul
‎2005 Dec 08 12:20 PM
Hi Abdul,
thanks for your answer.
The BAPI you mentioned calls a dialog. I need a remote BAPI (Material with reference) with no dialog to call it from PHP.
Any ideas?
Thanks in advance.
Steffen
‎2005 Dec 08 1:02 PM
Hi Steffen!
With BAPI_MATERIAL_MAINTAINDATA_RT it's no problem, but you have to use SAP-Retial.
But have a look at MATERIAL_MAINTAIN_DARK, if here more options are available.
Regards,
Christian
‎2005 Dec 17 1:43 PM
Hi Christian,
sorry for not writing sooner.
I need ab BAPI for standard material and it has to be a remote enabled function.
(i do not want to modify the function to remote enable it)
any mor ideas?
Thanks
Steffen
‎2005 Dec 17 1:53 PM
Hi Steffen
Have you tried to use the BAPI BAPI_MATERIAL_GET_ALL to get out the data you need to copy?
Max
‎2005 Dec 17 8:43 PM
Hi Steffen!
You can follow two different ways:
- Max's approach: reading all needed material data from reference material and copying this 'manual' into the bapi call.
- Write a RFC-function, which just calls the bapi_material_maintain_dark - you don't need to modify, you just have to 'translate' the interface definition. Of course check first, if reference material is provided.
Regards,
Christian
‎2005 Dec 20 8:09 AM
thank all of you guys,
i already found the GETALL BAPI, but i will have to map the structure of this BAPI to the structure of the _SAVEDATA BAPI.
... not really easy to use.
I just wanted to use RFC-Calls from outside SAP without having to change or write anything inside SAP. So Max's approach seems to be the only one.
regards
Steffen