Lesson Learnt: Pulling Data from SAP using BizTalk Orchestration using WCF LOB Adapter SDK SP2 and BizTalk Adapter Pack 2

1. Enable safe typing in the binding (this, more than often, will safe you headache of dealing w/ date and other numerical problem when converting one message to another in BizTalk (to and from SAP)

2. When pulling data from something like BAPI_EMPLOYEE_GETDATA that returns things back in an array, make sure you pass an empty node of the array that you are interested in inside the REQUEST message.  For example, in BAPI_EMPLOYEE_GETDATA... if you are interested in ARCHIVELINK and  PERSONAL_DATA being returned in the RESPONSE message, construct the REQUEST message like so:

<ns0:BAPI_EMPLOYEE_GETDATA>
  <ns0:AUTHORITY_CHECK>X</ns0:AUTHORITY_CHECK>
  <ns0:DATE>20090912</ns0:DATE>
  <ns0:EMPLOYEE_ID>0100001<ns0:EMPLOYEE_ID>
  <!—Here is the tricky part, need to add these empty placeholders -->
  <ns0:ARCHIVELINK>
    <ns1:BAPITOAV0 xmlns:ns1=”…” />
  </ns0:ARCHIVELINK>
  <ns0:PERSONAL_DATA>
    <ns1:BAPIP0002B xmlns:ns1=”…” />
  </ns0:PERSONAL_DATA>
</ns0:BAPI_EMPLOYEE_GETDATA>

and pass it to BizTalk to pass to SAP.  SAP will then return the two nodes w/ the appropriate content.

3. Use Add Generated Item, Consume Adapter Service to create the appropriate SAP binding file.

Share this post: | | | |
Published Saturday, September 12, 2009 1:05 AM by Jimmy Chandra
Filed under: ,

Comments

# re: Lesson Learnt: Pulling Data from SAP using BizTalk Orchestration using WCF LOB Adapter SDK SP2 and BizTalk Adapter Pack 2

akhirnya di post di blog nih jimmy.mantap

Sunday, September 13, 2009 9:31 PM by agusto

# re: Lesson Learnt: Pulling Data from SAP using BizTalk Orchestration using WCF LOB Adapter SDK SP2 and BizTalk Adapter Pack 2

Semoga tar gak menemukan kesalahan lagi ya jim :D, tapi jangan lupa jim cari juga cara kalo kita mau add service schemanya dari BAPI lebih dari 1, tar ketika kita mau panggil dari Biztalk Administrationnya pastikan apakah tagnya sama atau gak, thanks ya

Monday, September 14, 2009 11:38 AM by rahmad76

# re: Lesson Learnt: Pulling Data from SAP using BizTalk Orchestration using WCF LOB Adapter SDK SP2 and BizTalk Adapter Pack 2

great .net information thank you man...

Thursday, August 5, 2010 9:33 PM by web tasarim