cancel
Showing results for 
Search instead for 
Did you mean: 

PAPI WS getting SFCAssyRef for RemoveNonBOMComponents

Former Member
0 Kudos

Hi,

I am using the PAPI WS in SAP ME 6.0.4 and trying to figure out how to use the RemoveNonBOMComponents web-service.

My working Web-service looks like this:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:mep="mepapi:com:sap:me:production" xmlns:prod="http://www.sap.com/me/production" xmlns:com="http://www.sap.com/me/common">

   <soapenv:Header/>

   <soapenv:Body>

      <mep:removeNonBomComponents>

         <!--Optional:-->

         <mep:Site>TEST1</mep:Site>

         <!--Optional:-->

         <mep:Request>

            <!--1 or more repetitions:-->

            <prod:removeComponentList>

               <prod:event>baseFinished:AssemblyPoint</prod:event>

               <prod:quantity>1</prod:quantity>

               <prod:qty>1</prod:qty>

               <prod:sfcRef>SFCBO:TEST1,SE094700CN</prod:sfcRef>

               <prod:componentRef>ItemBO:TEST1,3EST000215-9350,X1</prod:componentRef>

               <prod:sfcAssyRef>SFCAssyBO:SFCBOMBO:SFCBO:TEST1,SE094700CN,4,ItemBO:TEST1,3EST000215-9350,X1</prod:sfcAssyRef>

            </prod:removeComponentList>

         </mep:Request>

      </mep:removeNonBomComponents>

   </soapenv:Body>

</soapenv:Envelope>

For the sfcRef and componentRef I can use the ObjectResolverService to find the appropriate handle, but I can not figure out how to get the sfcAssyRef handle.

Anybody that have experience of this and can help me?

Best Regards,

Johan Nordebrink

Accepted Solutions (0)

Answers (1)

Answers (1)

0 Kudos

Hi Johan,

Have you found the answer or it is still actual question?

Br, Alex.

Former Member
0 Kudos

Hi Alex,

Actually I did not need to use that WebService so that is why I have forgotten about it.

But yes.. it is still an actual question.. How can you use the ObjectResolver Webservice to get an SFCassyRefBO?

Best Regards,

Johan

0 Kudos

Hi Johan,

Just have tested the following request in ME 6.0.4.6:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:mep="mepapi:com:sap:me:production" xmlns:prod="http://www.sap.com/me/production" xmlns:com="http://www.sap.com/me/common">

   <soapenv:Header/>

   <soapenv:Body>

      <mep:removeNonBomComponents>

         <!--Optional:-->

         <mep:Site>ATX</mep:Site>

         <!--Optional:-->

         <mep:Request>

            <!--1 or more repetitions:-->

            <prod:removeComponentList>

               <prod:event>baseFinished:AssemblyPoint</prod:event>

               <prod:sfcRef>SFCBO:ATX,ATX55</prod:sfcRef>

               <prod:quantity>1</prod:quantity>

               <prod:qty>1</prod:qty>

               <prod:componentRef>ItemBO:ATX,COMPMAT1,A</prod:componentRef>

               <!--Optional:-->

               <prod:sfcAssyRef>SFCAssyBO:SFCBOMBO:SFCBO:ATX,ATX55,1,ItemBO:ATX,COMPMAT1,A</prod:sfcAssyRef>

            </prod:removeComponentList>

         </mep:Request>

      </mep:removeNonBomComponents>

   </soapenv:Body>

</soapenv:Envelope>

The component was removed successfully:

<SOAP-ENV:Envelope xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

   <SOAP-ENV:Body>

      <ns4:removeNonBomComponentsResponse xmlns:ns3="http://www.sap.com/me/common" xmlns:ns2="http://www.sap.com/me/production" xmlns:ns4="mepapi:com:sap:me:production">

         <ns4:Response>

            <ns2:removedComponentList>

               <ns2:sfcAssyRef>SFCAssyBO:SFCBOMBO:SFCBO:ATX,ATX55,1,ItemBO:ATX,COMPMAT1,A</ns2:sfcAssyRef>

               <ns2:assyId>1</ns2:assyId>

               <ns2:assyDataTypeRef>DataTypeBO:ATX,ASSEMBLY,INV_SFC</ns2:assyDataTypeRef>

               <ns2:inventoryRef>InventoryBO:ATX,ATX57</ns2:inventoryRef>

               <ns2:assembledDate>2013-06-27</ns2:assembledDate>

               <ns2:bomRef>BOMBO:ATX,BOM1,U,A</ns2:bomRef>

               <ns2:componentRef>ItemBO:ATX,COMPMAT1,A</ns2:componentRef>

               <ns2:timeBased>false</ns2:timeBased>

               <ns2:sfcBomRef>SFCBOMBO:SFCBO:ATX,ATX55</ns2:sfcBomRef>

               <ns2:bomComponentRef>BOMComponentBO:BOMBO:ATX,BOM1,U,A,ItemBO:ATX,COMPMAT1,A,10</ns2:bomComponentRef>

               <ns3:qty>1</ns3:qty>

               <ns2:itemRef>ItemBO:ATX,ASMAT1,A</ns2:itemRef>

               <ns2:operationRef>OperationBO:ATX,OP1,A</ns2:operationRef>

               <ns2:shopOrderRef>ShopOrderBO:ATX,20130627-19</ns2:shopOrderRef>

               <ns2:removed>true</ns2:removed>

            </ns2:removedComponentList>

         </ns4:Response>

      </ns4:removeNonBomComponentsResponse>

   </SOAP-ENV:Body>

</SOAP-ENV:Envelope>

So, I just took the corresponding handle from SFC_ASSY table.

Regards,

Alex.

Former Member
0 Kudos

Hi Alex,

Yes. I also got the web-service to work, but that was not my initial question.

I don't like having to build the whole SFCAssyRef string manually before sending the web-service request. This does not feel future-proof for me.

For other things, SFCRef, I can use the ObjectResolverService to automatically build up my string according to SAP ME standard and my question was how you could get the SFCAssyRef automatically in a similar way to make my coding more future-proof.

Best Regards,

Johan