JCo or JCA
I am currently working 4.6C and would like to move from ABAP to java enviornment.
Please let me know whether to use JCo or JCA for java web based development.
Thanks,
Harsha
Hi Harsha,
I think i can give conn infor here itself.
<b>Jco conn from ABAP to Java</b>
=====================
You can use the JCO RFC Provider Service of the Web Application Server for your ABAP to Java calls.
The steps involved in that are
1. Configure destination in SM59 in SAP.
2. Create RFC Destination in Visual Admin.
3. Create a stateless session bean with JNDI name as the name of calling function module in SAP.
4. Add a business method public void processFunction(JCO.Funtion fn) which is called by the JCO RFC Provider Service. The name should be 'processFunction'.
5. Set library references in application-j2ee-engine.xml to type weak for the following
a. com.sap.mw.jco.
b. com.sap.tc.Logging (if you are using the logging api )
Here is the sample code for the EJB biz method
Business Method.
public void processFunction(JCO.Function function) {
try {
// Get the import parameters for the function module
JCO.ParameterList importList = function.getImportParameterList();
logger.infoT("The value sent is" +
(String)importList.getValue("USER_NAME"));
// Set the export parameter value for the function module
JCO.ParameterList export = function.getExportParameterList();
export.setValue("From EJB", "RETURN");
function.setExportParameterList(export);
catch (java.lang.Exception e) {
e.printStackTrace();
<b>Jco conn from Java to others(ex:ABAP)</b>
=====================-==========
Open Visual Admin(C:\usr\sap\SID\JCxx\j2ee\admin\go.bat) and connect to server
Go to Destinations service
Open HTTP Settings Tab
Add/Edit destination SLD_DataSupplier and type following values
URL http://xyz.corp:53000
Authentication - BASIC
User dynproxxx
Password - bp52st000
Press save and test (if you get response code 200 everything is o.k.)
Add/Edit other HTTP Destination named SLD_Client with the same values as SLD_DataSupplier:
URL http://xyz.corp:53000
Authentication - BASIC
User dynproxxx
Password - bp52st000
Press save and test (if you get response code 200 everything is o.k.)
Go to SLD Data Supplier service.
Press the button named: Send the Data to SLD and confirm triggering SLD Data transfer (if you receive successful message everything is o.k.).
===================
following blog might helpfull
=======================
/people/michal.krawczyk2/blog/2005/03/10/registering-a-new-technical-system-in-sld--abap-based
for basic infor
==============
http://help.sap.com/saphelp_nw04s/helpdata/en/21/84570b3ae14e77b3047c82218974b9/frameset.htm
Award points if it helps
Similar Messages
-
How do I get started replacing JCo with JCA?
Hi all,
After upgrading to EP SP15 I'm now reading that I should stop using JCo for client connection and start using JCA.
I've searched but can't seem to find any step-by-step procedure that shows me how to convert my existing Java code to be JCA-compliant.
Basically, I was doing client = poolEntry.getClient() and then using the client.execute("myrfc"). What code change is required to replace that code with JCA code?
Thanks,
MikeHey Mike,
Glad I could help!!
There have been a couple things that I have noticed. If you are using a table as an input parameter, use a table.close() once you are done filling it and before adding it to the importParams("table_name",table) code. I have two scenarios for that. Here is the first:
for (int j = 0; j < exportTable.length; j++) {
table.insertRow();
table.setString("VAR1", exportTable[j][0]);
table.setString("VAR2", exportTable[j][1]);
table.close();
importParams.put("EXTAB", table);
,and the second one:
table.insertRow();
table.setString("VAR1", "This is variable 1");
table.setString("VAR2", "This is variable 2");
table.close();
importParams.put("EXTAB", table);
We are running EP6 SP14. In that booklet, it doesn't show using table.close(). You may not have to use it, but for me, I couldn't get it to work any other way. Once it was working, I removed it, and I would receive nothing.
Other than that right now, I haven't really run into any other problems... yet... haha.
Cheers,
Kevin -
Hi,
which of these is recommended to use and why?
thanks
JJHi Jiri,
JCo is the SAP specific way to access SAP from Java. It has been the officially recommended but proprietary technology as long as there hasn't been a generic solution for accessing "backends" (EIS). For history reasons this holds for EP5.
JCA is such a generic technology ( see http://java.sun.com/j2ee/connector/index.jsp ). So it has also become the officially recommended technology for accessing SAP from EP6 on.
Hope it helps
Detlev -
Hi all,
I searched for JCO/JCA topics in the forum, but I confused some terms/usages about them. Could anyone clarify for me:
1. What is different between JCO and JCA? Does JCA have the api to programming as JCO? From EP 6, JCO is deprecated, we use JCA to connect to SAP instead, is it right?
2. With JCO, what is JCO Destination, JCO inbound, JCO outbound? When we need to configure JCO Destination?
3. If we develop a portal application (ex: JSPDynPage)/ a WebDynPro application to get data from SAP, do you need configure JCO (in SLD, in EP, ...) or we just need use JCO API in code? How do we configure it?
4. What is Adaptive RFC?Hello
a short answer to some of your questions
1. What is different between JCO and JCA?
JCO is a SAP java library to connect to a SAP R/3 System. it can be used by independant (ie non-portal) application.
JCA, as i understand it, is a library whose structure as been defined by Sun, to connect to external system. The JCA implementation in the portal is based on JCO, and is to be used in the portal.
3. If we develop a portal application (ex: JSPDynPage)/ a WebDynPro application to get data from SAP, do you need configure JCO (in SLD, in EP, ...) or we just need use JCO API in code? How do we configure it?
If you use WebDynpro, you configue JCO in the WAS, and then use the plugins to create connections to R/3 RFC Functions.
If you develops standard Iviews (JspDynPage or Dynpage), you use the JCA api to get a connection to an alias, that itself point to a (R/3) system that has been defined in the portal administration.
Regards -
[Business Connector] JCo
Hi all,
I have the following problem regarding Business Connector issuing IDoc for a SAP Backend system to process.
Since BC is waiting for the complete integration of the IDoc to send the next one, the process is quite long !
Thus, I had several questions regarding Business Connector :
1) Does Business Connector necessarily rely on JCo to connect to SAP Backend systems or is there another way ?
2) If yes, is it possible to configure pooled connection instead of direct connection as it seems to be the default behaviour
3) Has anyone experiences multiples connections to the same SAP Backend system from one instance of Business Connector ?
4) Is this possible to configure SAP Business Connector in order not to wait for the complete integration ?
5) Is this possbile to configure ALE in order to only issue a receipt confirmation to SAP Business Connector (with the purpose to fasten the whole process) ?
Thanks for you help!
Best regards,
GuillaumeHi,
1)SAP Business Connector is a SAP native Message Server.
SAP JCo is native Connector from/to R/3 to/from the Java world.
SAP Java Resource Adapter is a Connector which currently applies to JCA 1.0.
2) neither SAP Business Connector nor SAP JCo meets JCA specifications.
regards,
Eugen -
Creating XML using JCA functionality
dear friends,
I am working on connection of EP to R3 using JCO and JCA architecture.
Using JCO, i could able to create XML file
i.e.,
JCO.Table sales_orders =function.getTableParameterList().getTable("KOMV");
sales_orders.writeXML("F:
usr
crpts
" + request.getUser().getUniqueName() + ".xml");
In the same manner i would like to create XML file using JCA functionality. But i did't found any functionality in any way as my knowledge.
can anybody help me out this
Secondly,
is it possible to create XML file with in the par path?
like instead of desktop F:
usr
crpts
path i would like to use like dist/xml
suggestion required.
Kanthadear friends,
I am working on connection of EP to R3 using JCO and JCA architecture.
Using JCO, i could able to create XML file
i.e.,
JCO.Table sales_orders =function.getTableParameterList().getTable("KOMV");
sales_orders.writeXML("F:
usr
crpts
" + request.getUser().getUniqueName() + ".xml");
In the same manner i would like to create XML file using JCA functionality. But i did't found any functionality in any way as my knowledge.
can anybody help me out this
Secondly,
is it possible to create XML file with in the par path?
like instead of desktop F:
usr
crpts
path i would like to use like dist/xml
suggestion required.
Kantha -
Connection to SAP R/3 46B through EP
Hi All
I installed following products but don't know how to connect SAP R/3 system through webdynpro.
EP : 6.0 SP10 (Only Java instance)
OS : Windows 2000
DB : Oracle 9i
R3 : Version 46B BASIS SUPPORT PACK 30
OS : Solaris 8
DB : Informix 7.31 fd2x9
Am new to NETWEAVER programming my desire is to connect
SAP and fetch data from SAP pl guide me.
Thanks in advance
Sanjay...and for "classical" portal development (i.e. PAR files), first create a system object in system administration --> system configuration --> system landscape and set all configuration parameters for your R/3 system accordingly there.
Next decide on you you like to implement SSO to this system (user mapping or SAP logon tickets). For the latter one, some additional steps need to be performed on the R/3 side. Please check service.sap.com/securityguide for this or do a search on the SDM forums on "sap logon tickets". There also are various nice weblogs on this, e.g. Quick Guide for setting up SSO between EP and R/3
Now for the "data fetching" part. This will require doing an RFC call from EP to your R/3 system. For this, you usually utilize SPA Java Connector (JCo) through JCA. This archive https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/jca on ep6 building portal applications.zip
contains all neccessary information.
Hope this helps, if so please do not forget rewarding points.
Regards,
Dominik -
Hi
Just wanted to know if the JCO client service is the only way of connecting to an SAP system from enterprise portal.
thanks
RamHi Ram,
no, it's the "old" way, the new one goes via JCA; see JCA/J2EE Connector Architecture with WAS 6.20 (R/3 Enterprise) and JCO x JCA and Java to SAP as well as the brand-new article https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/using j2ee connector architecture with ep6 iview development.pdf
Hope it helps
Detlev -
Hi all
I have recently started working in an organization as an ABAP programmer. Earlier, as part of my curriculum, I have designed a couple of systems using UML and coded the same in JAVA. Having worked on OO systems, I have a few questions to ask about ABAP and Web AS.
1) Does a company implementing SAP 6.0/ECC 6 have to decide in advance whether it will be coding its business logic/applications in JAVA or ABAP? Or Wes AS can process both languages once installed.
2) If a program is written in OO ABAP as well as in JAVA for a given business scenario (using the same OO (UML) structure) and executed on a Web AS, which one will perform better? Why?
3) Why is it that organizations, in spite of the visible benefits of OO programming, are unwilling to let go of procedural ABAP and adapt OO ABAP? Anyways, they dont have to convert their existing code but just to begin any new development using OO concepts. Is it because programs written in ABAP are usually not that complex to be modeled in OO concepts or there are not many people who know both ABAP and OO concepts.
Regards,
Anoop Sahu1) If a company is implementing ECC, it is all written in ABAP. THe R/3(ECC) backend system is comprised entirely in ABAP, so there is no decision, if you want to develop an application in ECC(R/3), you use ABAP. If you want to develop a java based application to access the ECC backend, you may do so using tools like jCo and JCA, and the webdynpro java environment supplies tools for you to access the backend. You can not directly access the ABAP backend data/tables from a java application, you must use the data access tools mentioned. Of course you need the java add on, or a standalone java application server to do this.
3) A lot of shops are used to the procedural ABAP model and have not yet had a need to implement an application using OO concepts, there are advantages, but an application does not have to use it. In some cases, it is a better way to go, but really it is all about the design, using ABAP OO is really not worth it without a good design. It is advantagious for ABAPers to imbraced ABAP OO concepts as this will be the design paradigm of future developments in ECC. In order to understand how a standard program works, they will need to know OO concepts.
Regards,
Rich Heilman -
Connecting to desktop Java application from R/3
I want to connect to a java application program in my desktop and return a parameter to R/3. I have installed Java connector and I want to call the java application from R/3 using Java connector.
I was able to get few samples to setup the RFC destination for a remote server program, but I was not able to find anything for an application in the client system. How to setup the RFC destination for a Java connector to call the application in the desktop? Can anyone please answer this question.Hi Allam,
1. Why do you need to connect from backend system to your desktop client? Did I understood it correctly that it's exacly what you want to do?
2. I guess examples you saw are for JCO or JCA which is a part of SAP J2EE server. Simply speaking the server is waiting for a client request and your desktop application probably not. If you still are sure that server->desktop connection is what you need then you have to emulate the server on your self and then depending on what you need JCO/JCA you have to create a kind of container that will implement listening service.
I'd like to hear your answer for question one to give you more detailed answer. -
Topics on EP and the sequence to be followed
Hi ,
I have explored a few topics on the development side of the portal and there are a few on my mind .What I wish to know is if I have to develop a team of delivery capability then in what sequence these topics are to be taken with the team . I am listing the topics below . Please guide as I have never been on a project on EP so I am not aware about the importance of these topics and the sequence to be followed while taking them up with a team .
Iviews : These include
Making iviews using standard templates available .
Making iviews using visual composer .
Making customised iviews using PDK(NDS and WAS) .
Webdynpro application
JSPDynpage
Business Packages
Integration of Third party applications
Configuring your mail server with the portal .Learning the configurational concepts of the exchange server .
BSP applications
HTMLB and tableviews
BISDK and XMLA
Using JCO and JCA
Knowledge/content management
Collaboration
TREX
If you have some other topics in mind please feel free to include here and also specify where do you wish to include them in the sequence . I need to know how do we go about this as it becomes quite confusing as to what to persue and with what importance as I have never faced a real time client requirements.
I AM LOOKING FOR AN EXPERT ADVICE HERE .
Regards
Deepak SinghHi deepak
I think you can go for this sequence
Making iviews(Making iviews using standard templates available .) and other pcd objects like worksets,pages etc..
Creating users,roles and Assinging roles to users
Making iviews using visual composer.
Knowledge/content management
Customization of portal.
Webdynpro application
JSPDynpage,HTMLB and tableviews
Making customised iviews using PDK(NDS and WAS).
Using JCO and JCA
Creating systems
Configuring your mail server with the portal.Learning the configurational concepts of the exchange server .
Integration of Third party applications
Collaboration
TREX
Business Packages
BSP applications
BISDK and XMLA
Regards
Geogi -
SAP WAS Evaluation useful if I have no R/3 system here?
Hi,
I am a little confused about the expressions Mini-SAP, SAP WAS Developer Edition etc. Sometimes I find postings that make me think these are the same, sometimes not.
I am working for a company doing J2EE development but we have no R/3 system here. Once I did a project where our app accessed a remote R/3 system by JCo. Testing was not easy because tests had to run at the customers site.
I would like to improve my knowledge - so I wonder if the SAP WAS Developer Edition (or the Netweaver Sneak Preview) will allow me to experience with things like JCo or JCA connectors here.
Thanks
MichaelI received the free DVD SAP WAS 6.4 from SAP. From what I see it's just what the name says - a J2EE server.
From the description of the book "ABAP Objects" by Keller/Krüger I read that it ships with two CDs having a Mini-SAP 4.6 and a WAS 6.1 on it. Because it's a combined distribution, this must be the reason why the expressions Mini-SAP and WAS are sometimes mixed. So I think this is what I need. I shall order it. This Mini-SAP seems to be no longer available by SAP directly.
Michael -
Portal component development-personlization
hi,
can anyone tell syntax of date ?
i wrote some code.But it give run time error.
in java file :
profile.getProperty("date");
profile.getPropertyAttribute("date","type");
response.write(profile.getProperty("date"));
in xml file :
<property name="date" value="">
<property name="personalization" value="dialog"/>
<property name ="type" value="Date"/>
</property>
after wrote that code it give :
Portal Runtime Error
An exception occurred while processing a request for :
iView : com.sap.portal.appdesigner.framework.profile
Component Name : com.sap.portal.appdesigner.framework.profile
For input string: "".
Exception id: 07:46_09/01/08_0794_2739150
See the details for the exception ID in the log fileHi Khushboo,
The "formal" way to extract data from R/3 is by calling BAPI functions. this is not wise to access R/3 tables directly, since consistent data saved on more then one table.
Therefore you should only use JCo or JCA to retrieve Data from a backend system via BAPIs or your own RFC enabled Function Modules.
Regards, -
Hello!
Because I can't get the SAP connector to work using SSO, I'm using the code from the PDK documentation with hardcoded login information. This is working, I get a connection to the R3 System. But how can I retrieve the data from a table? I want to display some formatted table data in the portal. Can you give me any hints or point me to a documentation/tutorial/article that covers this topic?Hi Sönke,
well, I think the easiest way to get R/3 information out on the portal is using a transaction iView ... but I guess that is not what you are looking for.
Otherwise, as you have written, the SAP Connector is a simple way of interfacing the R/3 system. The following document contains a very good description of how to interface SAP:
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/jca on ep6 building portal applications.zip
The document presents all resources you need. If you are considering whether to use JCO or JCA, this will help:
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/using sap adapter for connector framework
If you need any help regarding your development - just ask.
Cheerios. -
Accessing BAPIs in JSP Dynpage
Dear Experts,
I need to access BAPIs in my JSP Dynpage applications. As per my understanding, there are in two ways we can acheive this JCO and JCA. I would like to know the difference between these two methods ibased on performance.
Any pointers? Thanks for your help!
RamHi ,
Please take a look at the below links.
http://help.sap.com/saphelp_nw2004s/helpdata/en/f5/cfa441cd47a209e10000000a155106/frameset.htm
JCA
Hope these will help.
Thanks,
Sandip
Maybe you are looking for
-
We are trying to 'reconnect' files. we seem incapable to do so, for some reason. Try as we might, we aren't able to do it. can anyone help?
-
Hi I have just started using imovie for the first time as used to have a PC with Pinnacle for video editing. How do i create a front menu page, so that on there, there will be various titles that the user can easily select to then jump to that chapte
-
Sorting photos on iPhoto by device
Hi, I was wondering if anyone could help with sorting photos on iPhoto on a MacBook Air. I have synced photos from two separate iPhone 5 devices that were under the same iCloud account and I would like to sort them by the devices. I cannot exactly re
-
JAVA ME - Problems compiling and running (using Eclipse)
Hello, I am new to Java ME and I am trying to run a copied HelloMIDlet application. I am getting following error when I am trying to run the application: Running with storage root C:\Users\Niklas\j2mewtk\2.5.2\appdb\MediaControlSkin Running with loca
-
How to play music cd in Rhythmbox? (or anything else)
The situation is this: I can play music in Ryhthmbox that is on my hard disk (copied over from other distro) and am listening to jazz as I write this), but I can not put a CD into my dvd drive and play a music CD. I would like to rip it to disk using