I have to develop a Web-based application using IBM Websphere Application Server that accesses SAP using J2C connectors. My problem is that I need to run ABAP programs that access (update/insert/delete) custom "Z tables" in SAP. How can I run ABAP programs from VisualAge for Java (using Websphere J2C connector for SAP)?
The best way to run ABAP programs through a Java-based interface is to RFC-enable them. By creating an RFC wrapper around your ABAP programs, you allow the R/3 application server to effectively manage any communication from the outside world. If you have already written the application in ABAP, then you simply need to go into the Function Builder (SE37), create a new RFC with the requisite parameters, insert your ABAP program, and check the 'RFC Enable' box under Administration.
If you are doing simple table lookups, you may want to build your application logic in Java (e.g. when and what data is retrieved) and use RFCs such as RFC_READ_TABLE to connect to R/3. This allows you to maintain your application outside of SAP and means that you can leverage some of the more advanced features of Enterprise Java (messaging, EJBs, etc.).
Dig Deeper on SAP Java and J2EE
Related Q&A from Austin Sincock
How to provide an SAP R/3 4.5B application server with a Web service interface Continue Reading
A reader wants to know how to consume a Web service from an SAP 4.6c R/3 application server. Continue Reading
Are you a Java/J2EE developer interested in SAP? This expert tip lists the most relevant SAP modules and technologies for you. Continue Reading
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.