Home Page › Forums › BizTalk 2004 – BizTalk 2010 › Invoking BAPI using Biztalk Server 2006 BTS2006
- This topic has 4 replies, 1 voice, and was last updated 9 years, 8 months ago by
community-content.
-
AuthorPosts
-
-
May 18, 2008 at 3:12 AM #19691
Hi all..
I had problem …while Invoking BAPI using Biztalk Server 2006(BTS06)…can i use SAP adapter instead of WCF adapter in send port..i welcome the comment if someone can give me how can i make the solution ..
i am actually have a task where i need to send customer data to SAP in reponse SAp will return response xml containing voucher number…now when i make simple solution where i include RFC using add generated items.. and in orchestration i made one receive port (where i drop request xml) and send por to SAP and again after getting response from SAP store in some location…so when i generate instance of request schema..and send to SAP it recognises the the customer data generates the vouvher number but the field in response xml its empty…(whether voucher number is generated or not..i checked on SAP and its generating)
Guys ..if someone can help me out what shuold be the solution to this task…i would really appericiate..
Thanks…
Sandeep Handa
-
May 21, 2008 at 12:37 PM #19712
It sounds like a problem with the BAPI to me. When we called a BAPI, we were able to view the response message the BAPI was sending back. Might want to check it on the SAP side and make sure it is populated correctly.
-
May 22, 2008 at 12:13 PM #19719
Is this a standard BAPI in SAP or is this a custom BAPI that you developed ? Are you using SAP R/3 or ECC 6 ? Do yuo have NetWeaver installed in your SAP environment ? You could probably try NetWeaver using WCF Adapter HTTP binding to send data to your BAPI. If the you can send me the XML structure of the BAPI I will be able to tell you wether the XML structure that is formerd by the BAPI wether its correct or not. As well as the ABAP code.
-
May 24, 2008 at 6:00 AM #19737
Hi Thomas…
I had checked on SAP the RFC is not BAPI its ABAP…
SAP is generating voucher number in SAP which i can cross check..and also when i send wrong data the ZMESSAGE field gets field with message which means SAP is responding to input xml…but not returning back PARK_DOC
here is the request xml which i am sending to SAP …
<ns0:Z_BC_FI_PARK_DOCUMENT_Request
xmlns:ns0=”http://schemas.microsoft.com/BizTalk/2003“>
<ZFILENAME> </ZFILENAME>
<I_BKPF>
<BUKRS>EGO</BUKRS>
<BLART>SK</BLART>
<BUDAT>2008-04-05</BUDAT>
<XBLNR>E02090</XBLNR>
<BKTXT>CL-070508-72M8VC:8903</BKTXT>
</I_BKPF>
<I_BSEG>
<BUZEI>1</BUZEI>
<BSCHL>40</BSCHL>
<UMSKZ></UMSKZ>
<SHKZG>S</SHKZG>
<DMBTR>7603</DMBTR>
<SGTXT>Car insurance paid vide cheq no 201942 dtd 9/4/08.</SGTXT>
<ZUONR></ZUONR>
<KOSTL>13200</KOSTL>
<ZSAKNR>624101</ZSAKNR>
</I_BSEG>
<I_BSEG>
<BUZEI>2</BUZEI>
<BSCHL>40</BSCHL>
<UMSKZ></UMSKZ>
<SHKZG>S</SHKZG>
<DMBTR>1350</DMBTR>
<SGTXT>petrol exps…………………….</SGTXT>
<ZUONR></ZUONR>
<KOSTL>13200</KOSTL>
<ZSAKNR>600200</ZSAKNR>
</I_BSEG>
<I_BSEG>
<BUZEI>3</BUZEI>
<BSCHL>50</BSCHL>
<UMSKZ></UMSKZ>
<SHKZG>H</SHKZG>
<DMBTR>8903</DMBTR>
<SGTXT>Expense : 8903……………………</SGTXT>
<ZUONR></ZUONR>
<KOSTL>13200</KOSTL>
<ZSAKNR>350012</ZSAKNR>
</I_BSEG><I_PARK_DOC>
<PARK_DOC> </PARK_DOC>
</I_PARK_DOC>
<ZMESSAGE>
<ZMESSAGE></ZMESSAGE>
</ZMESSAGE></ns0:Z_BC_FI_PARK_DOCUMENT_Request>
and here is the response xml i am getting from SAP..
<?xml version=”1.0″ encoding=”utf-8″ ?>
<BUKRS>ELCO</BUKRS><BLART>SK</BLART><BUDAT>20080514</BUDAT><XBLNR>E02090</XBLNR><BKTXT>CL-070508-72M8VC:8903</BKTXT></I_BKPF><BUZEI>001</BUZEI><BSCHL>40</BSCHL><UMSKZ /><SHKZG>S</SHKZG><DMBTR>7603.00</DMBTR><SGTXT>Car insurance paid vide cheq no 201942 dtd 9/4/08.</SGTXT><ZUONR /><KOSTL>13200</KOSTL><ZSAKNR>624101</ZSAKNR></I_BSEG><BUZEI>002</BUZEI><BSCHL>40</BSCHL><UMSKZ /><SHKZG>S</SHKZG><DMBTR>1350.00</DMBTR><SGTXT>petrol exps…………………….</SGTXT><ZUONR /><KOSTL>13200</KOSTL><ZSAKNR>600200</ZSAKNR></I_BSEG><BUZEI>003</BUZEI><BSCHL>50</BSCHL><UMSKZ /><SHKZG>H</SHKZG><DMBTR>8903.00</DMBTR><SGTXT>Expense : 8903……………………</SGTXT><ZUONR /><KOSTL>13200</KOSTL><ZSAKNR>350012</ZSAKNR></I_BSEG><PARK_DOC /></I_PARK_DOC></ns0:Z_BC_FI_PARK_DOCUMENT_Response>-
May 27, 2008 at 6:01 AM #19761
Sorry I forgot to put my name it was not Thomas who responded asking for the XML structure of the RFC.
You need to do the following on SAP to create your BAPI in a nutshell.
Define the BAPI Data structures ( using SE11 )
•Creating BAPI Function Modules (For each method )
•Defining BAPI Methods in the BOR from your ABAP program
•Documentation of the BAPI
•Generate ALE interface for asynchronous BAPIs
•Generate and release the BAPIYou also need to test your BAPI from within SAP before you start using it.
Make sure that your BAPI is visible in the BAPI explorer.Remember that when you are calling your BAPI from BizTalk if they are any changes that are made to your database you will need to call BAPI_TRANSACTION_COMMIT from within your BizTalk ochestration after you execute your main BAPI to commit those changes. Otherwsie the changes will only be temporary.
Good Luck,
Panashe
-
-
-
-
AuthorPosts
- The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.