cancel
Showing results for 
Search instead for 
Did you mean: 

Call ABAP Program from outside SAP

Former Member
0 Kudos

Hi all,

How can I call an ABAP program from outside SAP, for example from a C++ executable, a .NET assembly or a JAVA package ? Are their "adapters" provided by SAP for this ?

Angela

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Angela

You can use RFC to do so. SAP provides a rfcsdk with containing a library and various examples. Check this sap note for a start: 27517 - Installing RFCSDK

Also have a look at the related notes there.

Regards

Michael

Former Member
0 Kudos

Hi,

Thanks for the hint. I've googled around a little looking for "SAP Note 27517" or "27517 - Installing RFCSDK" but can't find the actual document.

Could you please tell me where can I find it ?

Angela

Former Member
0 Kudos

Hello again

You can try this link: [27517 - Installing RFCSDK|https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes/sdn_oss_bc_mid/~form/handler%7b5f4150503d3030323030363832353030303030303031393732265f4556454e543d444953504c4159265f4e4e554d3d3237353137%7d]

Also have a look at

Regards

Michael

Former Member
0 Kudos

Hi,

I don't have OSS or anything of the sort, I'm trying to learn NetWeaver and SAP development using "SAP NetWeaver 70 - Java and ABAP VMware Trial".

Is there any way to get information of using RFC to call ABAP programs besides these notes ?

Is there any other way to do what I can to do? For example, what if I develop an EJB inside NetWeaver, will I be able to access this from any J2EE client ?

Angela

Answers (3)

Answers (3)

chrisp_vigelius
Explorer
0 Kudos

Hi angela,

I am not sure whether this EJB solution will work at all - but surely this is much more complicated than necessary.

Here's an easier solution:

1.) wrap your report into a function module which is rfc-enabled (you cannot call reports directly from outside)

2.) use the SOAP wrapper (look at service "/bc/soap/rfc" in SICF) to call that function module via HTTP - no need to download and install anything, except maybe a SOAP library for your favourite language. Example is <a href="http://help.sap.com/saphelp_47x200/helpdata/en/2d/64d041e74911d6b2e400508b6b8a93/frameset.htm">here</a>.

You only need the RFCSDK (which is available for customers only) if you want GUI functionality, e.g. show popups and similar. But then, EJB won't be a solution either as that would be running on the server, not on the client.

Former Member
0 Kudos

Hi,

Thanks a lot fo this advice. This sounds like a nice way to go. I'm quite busy right now, but I'll be testing ASAP.

Thanks again.

Angela

Boris_Rubarth
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Angela,

as Olivier has already stated: RFC SDK is only available for SAP customers, and it is not part of the trial version.

Rgds, Boris

Former Member
0 Kudos

Thanks for this confirmation. So, now the question is, will I also hit a licencing wall if I try to do the same thing with J2EE. That is, if I try to create an EJB (hosted by SAP NetWeaver) and try to call that EJB from lets say JBOSS, will this be possible or will I need some "SAP EJB SDK" to be able to call the SAP EJB from standard J2EE clients?

Angela

Boris_Rubarth
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Angela,

well, RFC is SAP proprietary, but EJB not, so I do not expect such a "wall".

Rgds, Boris

Former Member
0 Kudos

Thanks,

Well I'm out to test right now.

Angela

Boris_Rubarth
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Angela,

as mho already stated:

For external connections to ABAP, the sap-proprietary "remote function call (RFC)" is a common way.

SAP delivers an RFC-library for this, and for some development environments SAP even offers a connector on top of this library to make connectivity more easy (SAP Java Connector, SAP Business Connector, SAP Connector for Microsoft .Net). An RFC is always starting function modules in ABAP, not ABAP programs, and these function modules need the attribute "remote-enabled".

(Remark: in the context of SAP NetWeaver Process Integration, SAP offers adapters for connectivity, also for ABAP systems.)

For ABAP systems on basis code line 6.20 and above, the remote-enabled function modules can externally be used as web services.

Information on RFC can be found in the SAP Help Portal http://www.help.sap.com, e.g. [RFC Call - Example Program|http://help.sap.com/saphelp_nw04/helpdata/en/3d/733760ccb411d2b4550060941936e3/frameset.htm]. A search in SDN provides links to the Help Portal as well.

>

> For example, what if I develop an EJB inside NetWeaver, will I be able to access this from any J2EE client ?

This part is beyond the ABAP question, and my guess is pretty simple: like on any other J2EE server.

Regards, Boris

Former Member
0 Kudos

Thanks a lot for these details, I'll be looking at all this.

Angela

Former Member
0 Kudos

Sorry, but is "SAP RFC SDK" supposed to be avalable for non SAP customers ? Looking around, I've found it but only for SAP customers. I'm not a SAP customer, I'm just trying to learn NetWeaver.

Angela

Former Member
0 Kudos

Hi,

>Sorry, but is "SAP RFC SDK" supposed to be avalable for non SAP customers ?

I would be very surprised if it would be the case...

I guess you could become a SAP customer by buying the SAP RFC SDK license.

Regards,

Olivier