JCO or SAP Connector Framework

Hello
I have seen in these links that JCO is deprecated:
http://help.sap.com/saphelp_nw2004s/helpdata/en/40/003c41325fa831e10000000a1550b0/frameset.htm
http://help.sap.com/saphelp_nw04/helpdata/en/89/8a185c148e4f6582560a8d809210b4/content.htm
Developers are supposed to use SAP Connector Framework, but it seems that this is a Framework only useful from a Portal Application. What I want to do is to invoke RFCs in a R3 System from a webapp using struts. I have done this using JCO.
Should I implement it using another solution?
Thanks in advance

Hi Marcos,
You can, of course, use SAP JCO in simple Java Project by importing needed Jars.
I provide you a sample of connection class with method that you can use for calling a function.
You can use method "showFunctionParameters()" to test your connection...
regards
package echoFunction;
import java.io.IOException;
import java.util.Properties;
import javax.swing.JOptionPane;
import com.sap.mw.jco.IFunctionTemplate;
import com.sap.mw.jco.JCO;
public class JcoConnection {
     private final String REPO_NAME = "REPO_01";
     private JCO.Repository repository;
     private JCO.Function function;
     private JCO.Client connection;
     private JCO.ParameterList paramImport;
     private JCO.ParameterList paramExport;
     private JCO.ParameterList paramTables;
     public JcoConnection() {
          // constructor
     public void connect(String sapClient, String userId, String passWord,
               String language, String server, String systemNumber) {
          connection = JCO.createClient(sapClient, userId, passWord, language,
                    server, systemNumber);
          connection.connect();
          repository = new JCO.Repository(REPO_NAME, connection);
     public void connect(Properties properties) {
          connection = JCO.createClient(properties);
          connection.connect();
          repository = new JCO.Repository(REPO_NAME, connection);
     public void disConnect() {
          connection.disconnect();
     public void useFunction(String functionName) {
          IFunctionTemplate ift = repository.getFunctionTemplate(functionName
                    .toUpperCase());
          function = new JCO.Function(ift);
          paramImport = function.getImportParameterList();
          paramExport = function.getExportParameterList();
          paramTables = function.getTableParameterList();
     public void execute() throws JCO.AbapException {
          connection.execute(function);
     public void setInputValue(String paramName, String valueInput) {
          paramImport.setValue(valueInput, paramName);
     public String toString() {
          return connection.getAttributes().toString();
     public static void main(String[] args) {
          JcoConnection sapConn = new JcoConnection();
          try {
               sapConn.connect(Utilities.loadPropertyFile("logon.properties"));
               sapConn.useFunction("STFC_CONNECTION");
               sapConn.setInputValue("REQUTEXT", "Echo text");
               sapConn.execute();
          } catch (IOException ex) {
               ex.printStackTrace();
          } catch (Exception ex) {
               ex.printStackTrace();
          sapConn.disConnect();
          JOptionPane.showMessageDialog(null, sapConn.showFunctionParameters());
     public String showFunctionParameters() {
          String paramText = "";
          paramText = "ECHOTEXT: t";
          paramText += function.getExportParameterList().getString("ECHOTEXT")
                    + "n";
          paramText += "RESPTEXT: t";
          paramText += function.getExportParameterList().getString("RESPTEXT");
          return paramText;
package echoFunction;
import java.io.FileInputStream;
import java.io.IOException;
import java.util.Properties;
public class Utilities {
     public static Properties loadPropertyFile(String filePath)
               throws IOException {
          Properties properties = new Properties();
          properties.load(new FileInputStream(filePath));
          return properties;

Similar Messages

  • Needed classes for sap connector framework

    Hello,
    when i installed sap netweaver developer studio 2.0.5 i become all needed classes for sap connector framework?
    Or i have to install the pdk? What are in the pdk for developer studio because the needed wizards are there (portal, sap connector ...)
    Thanks,
    Frank

    Torben, try to use class finder plugin as described here /people/maksim.rashchynski/blog/2006/08/14/the-story-about-how-2-eclipse-plugins-helped-me-to-make-a-lot-of-points-on-sdn-forum
    To save you some time:
    C:\usr\sap\J2E\JC00\j2ee\cluster\server0\bin\ext\tcconnconnectorframework\*.jar
    C:\usr\sap\J2E\JC00\j2ee\cluster\server0\apps\sap.com\com.sapportals.connectors.sap\connector\connectors\SAPCFConnector.rar\SAPCFConnector.jar

  • SAP Connector Framework Libraries

    I want to develop a Portal Component that uses the SAP Connector Framework. I installed the Eclipse Plugin und downloaded the libraries.zip from the EP. I can't find some libraries: GenericConnector.JAR and Connector.JAR
    Could anybody tell me where to find these libraries?

    Hi,
    you can find the two jar files within your portal installation:
    GenericConnector.JAR under ...\<SID>\j2ee\cluster\server0\bin\ext\com.sap.genericconnector
    and the connector.jar file under
    ...\<SID>\j2ee\j2eeclient
    Best regards,
    Marion

  • SAP Connector Framework JAR-files

    Hey guys,
    can anyone please tell me where I can get the JAR-files for the SAP Java Connector (especially those with the package "com.sapportals.connector*".
    Thanks and Best Regards,
    Torben

    Torben, try to use class finder plugin as described here /people/maksim.rashchynski/blog/2006/08/14/the-story-about-how-2-eclipse-plugins-helped-me-to-make-a-lot-of-points-on-sdn-forum
    To save you some time:
    C:\usr\sap\J2E\JC00\j2ee\cluster\server0\bin\ext\tcconnconnectorframework\*.jar
    C:\usr\sap\J2E\JC00\j2ee\cluster\server0\apps\sap.com\com.sapportals.connectors.sap\connector\connectors\SAPCFConnector.rar\SAPCFConnector.jar

  • SAP Connector Framework

    Hi folks,
    can someone please tell me where in the support portal I can download the file "SAPCFConnector.rar"? I can not find it manually and the search engine is really bad.
    Thanks in advance for all answers!
    Regards,
    Torben

    Hi,
    you can find the two jar files within your portal installation:
    GenericConnector.JAR under ...\<SID>\j2ee\cluster\server0\bin\ext\com.sap.genericconnector
    and the connector.jar file under
    ...\<SID>\j2ee\j2eeclient
    Best regards,
    Marion

  • Issue with - Connector Framework  SAP EP 7.0

    HI
    Need assitance on usage of connector framework to connect to SAP R/3 using SSO.
    I am trying to call a BAPI from a jsp iView using sap connector framework.
    Release :  EP (SAP NetWeaver 7.0 (2004s) SPS 12).
    Steps I did so far :
    1. imported following jars in my project :
    a. activation.jar
    b. connector.jar
    c. GenericConnector.jar
    d. jaas.jar
    e. jta.jar
    f. portal_services_api_lib.jar
    2. declared import of class:
    <%@ page import = "com.sapportals.portal.ivs.cg.*" %>
    <%@ page import = "com.sapportals.connector.connection.IConnection" %>
    <%@ page import = "com.sapportals.connector.execution.structures.*" %>
    <%@ page import = "com.sapportals.connector.execution.functions.IInteraction" %>
    <%@ page import = "com.sapportals.connector.execution.functions.IInteractionSpec" %>
    3. appended portalapp.xml with :
      <application-config>
        <property name="SharingReference" value=",com.sap.portal.htmlb,com.sap.portal.pagebuilder,com.sap.portal.themes.lafservice,com.sap.portal.navigation.service,com.sap.portal.navigation.helperservice,com.sap.portal.license.runtime,com.sap.portal.common.commonservices,SAPJ2EE::library:com.sap.portal.common,com.sap.portal.ivs.connectorservice"/>
      </application-config>
    4. added following code :
         IConnectorGatewayService cgService = (IConnectorGatewayService) PortalRuntime.getRuntimeResources().getService(IConnectorGatewayService.KEY);
         IConnection connection = cgService.getConnection("ABC", request);
    <b>     IInteraction ix = connection.createInteractionEx();</b>
    5. Verfied connectivity of system alias ABC with connetion test from portal.
    When I test the repective iview after deployment it fails on the bold line with an error 'unable to deploy jsp'. I could verify that cgService and connection objects were initialized.
    Will appreciate expert comments/suggestions on the issue.
    Thanks and cheers,
    Amit.

    Hi,
    When you select that property, you get a value field in the bottom of the screen to enter the Cutom values.
    You can give the value there and click on the Set button.
    Also check the dbpool properties for this error code.
    Regards,
    Venkat

  • SAP Connector no longer working after upgrade

    After upgrading from EP 6.0 SP2 Patch 2 to Patch 3, our iViews using the SAP connector framework is no longer working. No connection is obtained. Even the examples in the PDK has stopped working. It seems that maybe some files have disappeared (in folder ".../server/services/eisconnector/work").
    Any ideas?
    Hilde

    Hi Hilde,
    1. please have a look in the Visual Admin Tool -> Services -> EISConnector ans see if the SAP Connector is deployed there. if you see it there, so it is deployed.
    2. try to remove and add agian the SAP Connector (in the same place as from section one)
    3. why dont you use the last Portal Patch and J2EE patch?
    4. do you see any special exception in the Log file?
    Regards,
    Aviad

  • SAP Connector

    Hello,
    when i will make a bapi call by the sap connector framework, what i have to do? Can i take the sap connector framework wizard? But i become a error-msg:
    Error This compilation unit indirectly references the missing type javax.resource.cci.ResourceAdapterMetaData (typically some required class file is referencing a type outside the classpath)     BspConnectorAppConnection.java     BspConnectorApp/src/com/gft/connector/connection     line 0
    Only the jdbc connector is default on the sap application server. When I will make a bapi call, which connector i need (java?) and i have to pay for that or not - example please?
    Thanks,
    Frank

    Hello Frank,
    have a look at this thread: How to read R/3 table and show it in SAP EP 6.0 I hope it helps.
    Regards
    Gregor

  • Difference Between SAP Connectors and SAP Web Services Framework

    Hello,
    I would like to know the main difference between the SAP Connectors protocol (that uses SOAP) and the SAP Web Services Framework starting with NetWeaver.
    Thank you,
    Pedro Carrilho

    Hi Pedro,
    I guess you are talking about Business Connectors and XI.
    If that is the case, the differences are:
    SAP XI belongs to SAP Netweaver Technology, whereas BC is an Integration tool provided by Webmethods.
    SAP XI is based on a model called "Hub & Spoke" and Business Connectors are "point to point". So by using XI, what happens is that you do not redesign Solutions once again.
    With XI you save the entire integration knowledge of a collaborative process centrally in SAP XI: Objects at design time in the Integration Repository and objects at configuration time in the Integration Directory. In this way, SAP Exchange Infrastructure follows the principle of shared collaboration knowledge: You no longer need to search for information about a collaborative process in each of the systems involved, but can call this information centrally instead. This procedure considerably reduces the costs for the development and maintenance of the shared applications.
    Also SAP XI comes with pre-configured solutions bundled along with it, so you can straight-away use the solution instead of redesigning.
    Also i believe SAP XI is integrated as a required solution for some new mySAP solution like SRM, there are some scenarios within SRM requires SAP XI to be used and we cannot use BC's there.
    But incase if you do not have multiple systems connected and communication is between just 2 systems, BC should be sufficient, instead of investing on XI.
    But i guess slowly SAP will be stopping its support for BC, as SAP XI can do everything that BC does and even much more.
    Also go through these threads...
    Re: Business connector
    XI vs Connectors (Like JCo and .NET)
    I hope this is what you were looking for...
    Regards,
    Abhy

  • Wanted 'Using Sap Adapter for Connector Framework' document

    dear friends
    I want to display ABAP reports in iView without Transaction iView.
    From the below forum link
    /community [original link is broken]
    i came to know i can get the help from 'Using Sap Adapter for Connector Framework' document, but the link is giving
    404
    The requested resource is not available.
    can anybody help me to find out the document
    thanx in advance
    please reply me at the earliest.
    kantha

    have a look here - should help:
    http://help.sap.com/saphelp_nw04s/helpdata/en/f2/db49421c0b3c54e10000000a1550b0/frameset.htm
    <a href="http://help.sap.com/saphelp_nw04s/helpdata/en/f2/db49421c0b3c54e10000000a1550b0/frameset.htm">sap help portal</a>
    you may also download PDK, there are some samples in it.
    Best Oliver

  • SAP Connector / Proxy Classes

    Hello,
    when i wont to call bapi-calls i need proxy classes. with the sap enterprise connetor they will be generated for JCo. Whats about calling with the connector framework? How i become the proxy-classes for my babi-call?
    Thanks,
    Frank

    Hi Michael,
    there is API documentation available on the SDN. The API docs of the SAP Java Connector is located here:
    http://media.sdn.sap.com/html/submitted_docs/60_sp2_javadocs/sapjco/index.html
    In general, API docs of Web AS 6.40 and EP components is available here:
    https://www.sdn.sap.com/sdn/developerareas/ep.sdn?page=javadoc.htm
    Hope that helps!
    Regards,
    Ivo

  • Connecting EP7.0 to iSeries backend system using the connector framework

    Hello All,
    We are trying to setup a backend connection in EP7.0 to an AS/400 Legacy database using the JDBC Connector framework.
    We use the driver and url syntax from OSS note 773401 "Configuring Portal JDBC System connection properties"
    Driver:
    com.sap.portals.jdbc.db2.DB2Driver
    URL: jdbc:sap:db2://<server>:<port>;DatabaseName=<database_name>
    When performing a connection check using the Support Platform, we can see on the legacy system that the connection is being established but for some reason the Portal doesn't get a confirmation and runs in to an endless loop...
    Does anyone have a experience with such a connection?
    Can we use the standard db2 driver class as mentioned in note 773401 or do we need to create/deploy our own?
    Thanks in advance
    Ron

    Hello All,
    We are trying to setup a backend connection in EP7.0 to an AS/400 Legacy database using the JDBC Connector framework.
    We use the driver and url syntax from OSS note 773401 "Configuring Portal JDBC System connection properties"
    Driver:
    com.sap.portals.jdbc.db2.DB2Driver
    URL: jdbc:sap:db2://<server>:<port>;DatabaseName=<database_name>
    When performing a connection check using the Support Platform, we can see on the legacy system that the connection is being established but for some reason the Portal doesn't get a confirmation and runs in to an endless loop...
    Does anyone have a experience with such a connection?
    Can we use the standard db2 driver class as mentioned in note 773401 or do we need to create/deploy our own?
    Thanks in advance
    Ron

  • File or assembly name SAP.Connector, or one of its dependencies not found

    Hello there,
    Something very strange is overcoming me when experimenting a little bit with the SAPConnector:
    I developped a class that is accessing the proxy-class generated by the SAPConnector wizard and I have put it into a class library. No problems so far.
    When I am accessing the class library from into a windows application, no problems are signalized...
    However when I try to execute the BAPI from another class library project, I always get the following message:
    File or assembly name SAP.Connector, or one of its dependencies, was not found.
    I am testing with the following configuration:
    - Visual PC 2004
    - .Net-framework 1.1 and .Net-framework 2.0
    - Visual Studio 2003 and Visual Studio 2005
    I tried both SAPConnector 1.0.3 and 2.0, but both return the same message.
    Thanks in advance!
    Greetz,
    Sven

    SAP.Connector.DLL (and SAP.Connector.Rfc.DLL in 2.x) must be available for the project to load. The easiest is to put the two DLLs into GAC (which is the default in NCo 2.x). You can also have them in you application directory. The reason that you don't see a problem if you are using NCo directly is the fact that VS automatically copies directly referenced DLLs into the target directory. This is not (allways) the case for inderectly referenced DLLs.

  • How to install Connector framework in WAS (j2ee)??

    I am connecting to mdm server through NWDS (ejb /dynpro) using connector framwork
    But i could not refer the package com.sapportals.connector.connection and sub sequent interfaces in that.
    I am basically dynpro guy and dont know how to use this connector framework.
    Please help in step by step installation of this for dev and runtime.
    thanks in advance.
    Hari.

    Hi
      To implement the connector framework, you should include the following jar files in your project, they are:
    <b>portal_services_api_lib.jar
    com.sap.portal.ivs.connectorservice_api.jar
    GenericConnector.jar</b>
    For the above jar files, check it under your NWDS IDE plugins folder
    (OR)
    If you have the Portal Development Kit installed on your portal server, you can find
    this library in Java Development --> Downloads --> Portal Libraries --> libraries.zip.
    Otherwise, look in:
    http://<server>:<port>/irj/servlet/prt/portal/prtroot/com.sap.
    portal.support.browse.default,
    and then follow this path:
    ROOT/WEBINF/
    portal/portalapps/com.sap.portal.ivs.connectorservice/lib
    Click the download link to download a zip file which contains this jar.
    Regards,
    Venkatesh. K

  • SAP Connector Proxy Wizard doesn't start

    Hi all,
    I've just installed VS2003, the SAP .NET connector and the .net framework (1.1) on a freshly installed Windows XP pro machine. If I follow the various tutorials on the web I should be able to create a SAP proxy when doing the following:
    - start VS2003
    - create a new Windows Application (in C#)
    - Add a SAP Connector Proxy
    -- A wizard starts
    And that is were it starts to go wrong. Instead of a wizard, I get the following:
    <?xml version="1.0" encoding="utf-8" ?>
    <wsdl:definitions targetNamespace="urn:sap-com:document:sap:rfc:functions" xmlns:s0="urn:sap-com:document:sap:rfc:functions" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
      <wsdl:types>
        <xsd:schema targetNamespace="urn:sap-com:document:sap:rfc:functions" xmlns:s0="urn:sap-com:document:sap:rfc:functions" xmlns:xsd="http://www.w3.org/2001/XMLSchema"></xsd:schema>
      </wsdl:types>
      <wsdl:portType name="dummy.PortType"></wsdl:portType>
      <wsdl:binding name="dummy.SAPBinding" type="s0:dummy.PortType" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
        <s0:binding style="rfc" />
        <wiz:GeneratorSettings xmlns:wiz="urn:sap:mw:dotnet:wizard">
          <wiz:ProxyType>Client</wiz:ProxyType>
          <wiz:ClassName>SAPProxy1</wiz:ClassName>
          <wiz:Beautify>True</wiz:Beautify>
          <wiz:CreateAsyncs>False</wiz:CreateAsyncs>
          <wiz:CreateQRFC>False</wiz:CreateQRFC>
          <wiz:CreateTRFC>False</wiz:CreateTRFC>
        </wiz:GeneratorSettings>
      </wsdl:binding>
      <wsdl:binding name="dummy.Binding" type="s0:dummy.PortType" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
        <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" />
      </wsdl:binding>
    </wsdl:definitions>
    Does anyone know what could be wrong here?
    Thank you and kind regards,
    Thomas

    Hi Thomas,
    With the newer version of NCo (> 2.0) there is no wizard. You would have to drag and drop the RFC/BAPI from the server explorer window of visual studio.
    First open the solution explorer, click on the SAP icon. Specify the credentials. And then from the list of RFC/BAPI drag and drop on SAP connector proxy page(design view). You can also specify the filter to restrict the listing of RFC/BAPI.
    Regards.

Maybe you are looking for

  • Keep getting error message when trying to dowmload iso6 on my iPhone 4s

    Error message keeps coming up when I am trying to finish download of iso6 please someone help

  • Reuirement at the time of delivery creation or change

    Dear All, Please guide me or give me your inputs to full fill the requirement that i have, At the time of creation of delivery or changing a existing delivery i need to raise a pop up window listing all the materials in the delivery and next to the m

  • Address Data cleanse

    Hi We have the Global Address Cleanse transform in Data Integrator We are using the Australia setting - can we get the DPID for the address ( the australia post, unique address delivery point identifier?) Do you guys use the australia post PAF file (

  • Upgrade path for WLC

    Hello all, We are planning to upgrade our controller 5508 from 7.0.116.0 to 7.1.91.0. Is this directly possible or i have to put some other image before directly upgrading it? please provide link stating this. KVS

  • Error while installing PIM Sync

    Hi, While installing PIM Sync an error is given "Installation found another product installed which uses the same configuration file settings. Installation was cancelled because they cannot function on the same computer. Please uninstall the other so