Issue in calling a web service from Apps instance

Hi ,
I have created a procedure to call a function which gives response by calling a web service URL.
Requirement is,
While calling this procedure , the response data has been stored in the table. This is working fine in the back end.
Now , i call the same through concurrenet program . It is also getting stored but partially.. The exact data is missing ..other default tags are displayed in the column.
PROCEUDRE:
create or replace procedure cv_test_GetCityWeather_PROC(cityName in varchar2, country in varchar2 ,errbuf OUT nocopy VARCHAR2,retcode OUT nocopy VARCHAR2) is
xmlResponse XmlType;
begin
xmlResponse := CV_Test_GetCityWeather(cityName,country);
insert into xx_cv_test values(xmlResponse);
fnd_file.put_line(fnd_file.log, 'hghghgh');
EXCEPTION
WHEN OTHERS THEN
retcode := 'insert failed';
fnd_file.put_line(fnd_file.log, 'response of the request is ' );
--dbms_output.put_line('xmlResponse ' ||xmlResponse);
end cv_test_getCityweather_proc;
FUNCTION
/*<TOAD_FILE_CHUNK>*/
CREATE OR REPLACE function APPS.CV_Test_GetCityWeather( cityName varchar2, country varchar2 ) return XmlType is
--// URL to call
SOAP_URL constant varchar2(1000) := 'http://www.webservicex.net/globalweather.asmx';
--// SOAP envelope template, containing $ substitution variables
SOAP_ENVELOPE constant varchar2(32767) :=
'<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://www.webserviceX.NET">
<soapenv:Header/>
<soapenv:Body>
<web:GetWeather>
<web:CityName>$CITY</web:CityName>
<web:CountryName>$COUNTRY</web:CountryName>
</web:GetWeather>
</soapenv:Body>
</soapenv:Envelope>';
--// we'll identify ourselves using an IE9/Windows7 generic browser signature
C_USER_AGENT constant varchar2(4000) := 'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)';
--// these variables need to be set if web access
--// is via a proxy server
proxyServer varchar2(20) default null;
proxyUser varchar2(20) default null;
proxyPass varchar2(20) default null;
--// our local variables
soapEnvelope varchar2(32767);
proxyURL varchar2(4000);
request utl_http.req;
response utl_http.resp;
buffer varchar2(32767);
soapResponse clob;
xmlResponse XmlType;
eof boolean;
begin
--// create the SOAP envelope
soapEnvelope := replace( SOAP_ENVELOPE, '$CITY', cityName );
soapEnvelope := replace( soapEnvelope, '$COUNTRY', country );
--// our "browser" settings
utl_http.set_response_error_check( true );
utl_http.set_detailed_excp_support( true );
utl_http.set_cookie_support( true );
utl_http.set_transfer_timeout( 10 );
utl_http.set_follow_redirect( 3 );
utl_http.set_persistent_conn_support( true );
--// configure for web proxy access if applicable
if proxyServer is not null then
proxyURL := 'http://'||proxyServer;
if (proxyUser is not null) and (proxyPass is not null) then
proxyURL := Replace( proxyURL, 'http://', 'http://'||proxyUser||':'||proxyPass||'@' );
end if;
utl_http.set_proxy( proxyURL, null );
end if;
--// make the POST call to the web service
request := utl_http.begin_request( SOAP_URL, 'POST', utl_http.HTTP_VERSION_1_1 );
utl_http.set_header( request, 'User-Agent', C_USER_AGENT );
utl_http.set_header( request, 'Content-Type', 'text/xml; charset=utf-8' );
utl_http.set_header( request, 'Content-Length', length(soapEnvelope) );
utl_http.set_header( request, 'SoapAction', 'http://www.webserviceX.NET/GetWeather' );
utl_http.write_text( request, soapEnvelope );
--// read the web service HTTP response
response := utl_http.get_response( request );
dbms_lob.CreateTemporary( soapResponse, true );
eof := false;
loop
exit when eof;
begin
utl_http.read_line( response, buffer, true );
if length(buffer) > 0 then
dbms_lob.WriteAppend(
soapResponse,
length(buffer),
buffer
end if;
exception when utl_http.END_OF_BODY then
eof := true;
end;
end loop;
utl_http.end_response( response );
--// as the SOAP responds with XML, we convert
--// the response to XML
xmlResponse := XmlType( soapResponse );
--dbms_lob.FreeTemporary( soapResponse );
--insert into xx_cv_test values(xmlResponse);
return( xmlResponse );
exception when OTHERS then
if soapResponse is not null then
dbms_lob.FreeTemporary( soapResponse );
end if;
raise;
end;
EXECUTION:
select cv_test_GetCityWeather( 'Cape Town', 'South Africa' ) from dual
Result is,
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<GetWeatherResponse xmlns="http://www.webserviceX.NET">
<GetWeatherResult><?xml version="1.0" encoding="utf-16"?><CurrentWeather> <Location>Cape Town, Cape Town International Airport, South Africa (FACT) 33-59S 018-36E 0M</Location> <Time>May 28, 2013 - 03:00 AM EDT / 2013.05.28 0700 UTC</Time> <Wind> from the NNW (330 degrees) at 7 MPH (6 KT) (direction variable):0</Wind> <Visibility> 4 mile(s):0</Visibility> <SkyConditions> mostly cloudy</SkyConditions> <Temperature> 57 F (14 C)</Temperature> <DewPoint> 53 F (12 C)</DewPoint> <RelativeHumidity> 87%</RelativeHumidity> <Pressure> 30.03 in. Hg (1017 hPa)</Pressure> <Status>Success</Status></CurrentWeather></GetWeatherResult>
</GetWeatherResponse>
</soap:Body>
</soap:Envelope>
While running Concurrent Program, by providing PARAMETERS : Cape Town, South Africa,
the result is ,
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<GetWeatherResponse xmlns="http://www.webserviceX.NET">
<GetWeatherResult>Data Not Found</GetWeatherResult>
</GetWeatherResponse>
</soap:Body>
</soap:Envelope>
Why the outputs are different for the same procedure..
Anybody , Please help me to fix this issue.
Thanks
Winsky

duplicate post
Please see
Calling webservice from PLSQL
Please confirm are you the one who post the above thread
;) AppsMAsti :)
sharing is Caring

Similar Messages

  • QName error while calling a web service from Sourcing

    I need to call a web service from Sourcing script. The web service team has provided us the WSDL and I have generated the required stubs using wsimport and packaged the required java classes in a custom JAR. Now while calling a web method using this jar from my script, I am getting and exception. The exception message that I printed out was this:
    Caught exception e with msg Connection IO Exception. Check nested exception for details. (Connection
    IO Exception. Check nested exception for details. (Connection Exception; nested exception is:
    java.lang.IllegalArgumentException: cannot create QName from "null" or "" String).)
    The same jar and same code works fine when called from a standalone java program.
    I am not using or creating QName anywhere in my script. The only place where QName is used is in the generated java class and there it is created from the correct namespace URL
    Can anyone please help me out in figuring out what is the issue?

    This is the stack trace of the error:
    #2.0 #2014 05 08 09:02:30:915#+00#Error#com.sap.engine.services.webservices.espbase.client.bindings.impl.SOAPTransportBinding#
    #BC-ESI-WS-JAV-RT#webservices_lib#C000CF8242BA4B800000002100002648#2174850000000005#sap.com/E-Sourcing-Server#com.sap.engine.services.webservices.espbase.client.bindings.impl.SOAPTransportBinding#VAC53324#89##D811EE96D68E11E3C9E0000000212F82#3cf7fe38d68f11e3c963000000212f82#3cf7fe38d68f11e3c963000000212f82#0#Thread[RequestHandler.RqThread: fullsave,5,Dedicated_Application_Thread]#Plain##
    Connection IO Exception. Check nested exception for details. (Connection IO Exception. Check nested exception for details. (Connection Exception; nested exception is:
        java.lang.IllegalArgumentException: cannot create QName from "null" or "" String).).
    [EXCEPTION]
    com.sap.engine.services.webservices.espbase.client.bindings.exceptions.TransportBindingException: Connection IO Exception. Check nested exception for details. (Connection IO Exception. Check nested exception for details. (Connection Exception; nested exception is:
        java.lang.IllegalArgumentException: cannot create QName from "null" or "" String).).
        at com.sap.engine.services.webservices.espbase.client.bindings.impl.SOAPTransportBinding.writeSOAPRequestMessage(SOAPTransportBinding.java:256)
        at com.sap.engine.services.webservices.espbase.client.bindings.impl.SOAPTransportBinding.call_SOAP(SOAPTransportBinding.java:1318)
        at com.sap.engine.services.webservices.espbase.client.bindings.impl.SOAPTransportBinding.callWOLogging(SOAPTransportBinding.java:991)
        at com.sap.engine.services.webservices.espbase.client.bindings.impl.SOAPTransportBinding.call(SOAPTransportBinding.java:945)
        at com.sap.engine.services.webservices.espbase.client.jaxws.core.WSInvocationHandler.processTransportBindingCall(WSInvocationHandler.java:168)
        at com.sap.engine.services.webservices.espbase.client.jaxws.core.WSInvocationHandler.invokeSEISyncMethod(WSInvocationHandler.java:121)
        at com.sap.engine.services.webservices.espbase.client.jaxws.core.WSInvocationHandler.invokeSEIMethod(WSInvocationHandler.java:84)
        at com.sap.engine.services.webservices.espbase.client.jaxws.core.WSInvocationHandler.invoke(WSInvocationHandler.java:65)
        at $Proxy2539.grantOrganizationRoles(Unknown Source)
    I tested the same custom JAR, that is deployed in Sourcing, separately using a standalone java program and there it gave back the correct SOAP response

  • How can we call a WEB SERVICE from an Oracle DB?

    <h2>
    What the methods available to call a WEB SERVICE from the DB. I.e. through a DB Stored Procedure?
    I was given this article by a colleague, but since it’s a 2005 one, I feel it could be outdated?
    http://www.oracle.com/technology/pub/articles/mensah_dws.html
    Also, is it possible to write ONE “Common” DB stored procedure to call ANY WEB SERVICE?
    </h2>

    <h2> No Girish, what I meant is, since it is 2005 article, the method it describes to call a WS is out of date.
    Because I am quite sure in 2009, 4 years later Oracle must have added built-in packages and other methods to simplify it???
    Also, I would be very grateful if you advice on the other issue: Is there a way to create a single DB stored procedure to call ANY WS?? i.e. a common routine to call any web service?
    </h2>

  • How to call a web Service from Oracle Applications?

    Hi friends,
    I've posted this question on OA Framework forum , but may be it's more appropiated put it here. Sorry for do it again:
    It's about how to call a web service from a Form or a .sql (via Request) in Oracle Applications:
    Could you please explain here the detailed steps (with code example if it's possible) to invoke a webservice from Oracle Applications?.. how did yo do it...?
    I've read differents posts here and the 33097.1 metalink note (by the way, the first recommended link in this note is broken...), but there are lots of theorical concepts and no real examples to see how/from where invoke the WS
    I'll have to call one webservice (I suppose the customer will give me the interface implementation)...but I've never did it with Applications so that's why I ask you for all the detailed steps...
    I work with Forms 6i, Apps 11.5.10.2 and DB 9.2.0.7.
    Thanks a lot.
    Jose.

    Hello Jose,
    I did using java program to call BPEL web services in 11.5.10.
    I pasted below the metalink note for your reference (Note:250964.1)
    The idea is first write a java program to call the webservice (in my case it is calling an BPEL web service, so this may not help directly), test it.
    Then port the java program as specified in the note, so that you could call your web service through concurrent manager scheduler.
    Is this ok?
    Thanks
    Arun.
    ======================================================
    Checked for relevance on 25-Apr-2007
    Application Install - Version: 11.5.8 to 11.5.10
    Goal
    ====
    How to register and create a Java concurrent program for Oracle Applications
    Release 11i
    Solution
    ========
    1. Create your Java Concurrent Program (JCP) , using a text editor.
    /*===========================================================================+
    | Concurrent Processing Sample Code |
    | |
    | FILENAME |
    | Hello.java |
    | |
    | DESCRIPTION |
    | Sample Java concurrent program |
    | About the simplest possible program, just writes a message to the |
    | logfile and output file. |
    | |
    | HISTORY |
    | $Log$ |
    | |
    +===========================================================================*/
    package oracle.apps.fnd.cp.sample;
    import oracle.apps.fnd.cp.request.*;
    public class Hello implements JavaConcurrentProgram {
    public static final String RCS_ID = "$Header$";
    public void runProgram(CpContext ctx) {
    ctx.getLogFile().writeln("-- Hello World! --", 0);
    ctx.getOutFile().writeln("-- Hello World! --");
    ctx.getReqCompletion().setCompletion(ReqCompletion.NORMAL, "");
    =======================================
    End Sample
    =======================================
    2. Create a sample directory under $JAVA_TOP:
    $ mkdir $JAVA_TOPoracle/apps/fnd/cp/sample
    3. Copy Hello.java into $JAVA_TOP/oracle/apps/fnd/cp/sample:
    $ cp $HOME/Hello.java $JAVA_TOP/oracle/apps/fnd/cp/sample
    4. Compile your java program:
    javac $JAVA_TOP/oracle/apps/fnd/cp/sample/Hello.java
    5. Test at the command line with following syntax:
    jre -Ddbcfile=$FND_TOP/secure/your_dbc_file.dbc \
    -Drequest.outfile=./outfile \
    oracle.apps.fnd.cp.request.Run \
    oracle.apps.fnd.cp.sample.Hello
    6. Register your custom java concurrent program with Oracle Applications.
    a. Navigate: Concurrent > Program > Executable
    b. Enter details into the form
    Executable: JCPHELLO
    Shortname: JCPHELLO
    Application: Application Object Library
    Execution Method: Java Concurrent Program
    Execution File Name: Hello (Insert a name that does not contain space or period)
    Execution File Path: oracle.apps.fnd.cp.sample
    c. Save the details
    d. Navigate: Concurrent > Program > Define
    e. Enter details into the form
    Program Name: JCPHELLO
    Program Shortname: JCPHELLO
    Application: Application Object Library
    Executable: Choose JCPHELLO from LOV
    Executable Options :
    f. Save the details
    7. Add this new concurrent request to your responsibility request group.
    a. Navigate > Security > Responsiblity > Request
    b. Query System Administrator
    c. Add new row and choose TestJava
    d. Save the changes.
    8. Run your new Hello Java Concurrent Program
    Navigate: Request > Run
    References
    ~~~~~~~~~~~
    Oracle Applications Developers Manual for Release 11i A75545-01
    ====================================================

  • Unable to call a web service from BPEL Project

    I am running my BPEL PM on Windows XP SP3. The platform is weblogic 9.2, SOA 10.1.3.1.
    I created a simple BPEL project to call a web service and when I run the project from BPELConsole I getting the following error:
    exception on JaxRpc invoke: HTTP transport error: javax.xml.soap.SOAPException: java.security.PrivilegedActionException: javax.xml.soap.SOAPException: Bad response: 407 Proxy Authentication Required ( The ISA Server requires authorization to fulfill the request. Access to the Web Proxy filter is denied. )
    I am able to call this web service from soapUI client.
    Any help or hint is appreciated.
    Thanks

    I have had this issue before when calling a .NET service, it was firewall related. I didn't actually make the fix so I can't tell you exactly how it was fixed on the server. I hope this info makes sense as this this the info I got from the IT boys
    I’ve install this tool on your computer:
    http://www.microsoft.com/downloads/details.aspx?FamilyID=05C2C932-B15A-4990-B525-66380743DA89&displaylang=en
    which does that:
    Firewall Client for ISA Server can be optionally installed on client computers protected by Microsoft ISA Server. Firewall Client for ISA Server provides enhanced security, application support, and access control for client computers. It provides authentication for Winsock applications that use TCP and UDP, supports complex secondary protocols, and supplies user and application information to the ISA Server logs.
    When a client computer running Firewall Client for ISA Server makes a request, the destination is evaluated by the Firewall Client software, and external requests are directed to the ISA Server computer for handling. No specific routing infrastructure is required. Firewall Client sends user information transparently with each request, enabling you to create a firewall policy on the ISA Server computer with rules that use the authentication credentials presented by the client. ISA Server allows you to configure automatic discovery for Firewall client computers, using a WPAD entry in DNS or DHCP to obtain correct Web proxy settings for clients, depending on their location.
    and I’ve added a exception in IE to the tools-lan settings-advanced-exceptions to be creditworks.* Did this by modifying the GPO that applies to your account, so all the users in National Office should have that exception.
    hope you can use this.
    cheers
    James

  • How to call a web service from BPEL that requires HTTP basic authentication

    Hi All,
    I need to calling some Web Services from BPEL (SOA 10.1.3.1 production running on XP machine). The services require HTTP basic authentication.
    I have tried adding httpUsername and httpPassword properties to the ParnterLink, and I see in BPEL Console that they are deployed by checking the descriptor page. But I still get a SOAP fault, HTTP 401: Unathenticated.
    I have also tried using basicHeaders (from memory) = credentials, httpBasicUsername, and httpBasicPassword. Same result.
    I have done a packet trace using Ethereal, and the headers do not seem to contain the userid and password at all.
    Can anyone help?
    Thanks,
    Mark Nelson

    Thanks Bas,
    I have resolved the issue. The provider of the Web Service had not configured if for Basic Authentication. For some reason it worked when they tested, or maybe the did not test. The only thing I had to change was to use:
    <property name="basicHeaders">credentials</property>
    <property name="basicUsername">WMDATA</property>
    <property name="basicPassword">WMDATA</property>
    Instead of:
    <property name="httpUsername">WMDATA</property>
    <property name="httpPassword">WMDATA</property>
    I don’t know why this is, maybe because it is an Axis Web Service.
    Sorry for wasting your time.
    Regards Pete

  • Call a Web Service from within an e-Sourcing script

    Hi Guys
    I would like to know wether anyone has successfully been able to call a Web Service from within an
    e-Sourcing script? If you have, can you please share your experience and code?
    Thank You

    Hi Faaiez -
    As with any use of Web Services, however, you should carefully consider the security issues that may come up. How, for example, will the Web Service server validate that the Web Service client (E-Sourcing) is properly authenticated? Will password information be included in the web service call? You will find that it is very easy to make a web service call, but I would encourage you to carefully consider security before implementing a productive solution.
    Web service calls can be made using raw Java web service APIs from the open source Axis library which is included with E-Sourcing; this approach is slightly more difficult to code, but very dynamic. Web service calls can also be made using proxies. In one solution that I worked on, we generated java proxies for the web service, compiled those proxies into a Jar file, and included that jar file as a custom jar in E-Sourcing. Let me provide a few more details on each of these approaches.
    Using raw java web service APIs that are part of the Service and Call classes, I prototyped a web service call to Googles sample spell checker web service. Here is the code:
    import org.apache.axis.client.Call;
    import org.apache.axis.client.Service;
    import org.apache.axis.encoding.XMLType;
    import javax.xml.rpc.ParameterMode;
    import javax.xml.namespace.QName;
    String endpoint = "http://api.google.com/search/beta2";
    Service  service = new Service();       
    Call call = (Call) service.createCall();       
    call.setTargetEndpointAddress( new java.net.URL(endpoint) );       
    call.setOperationName( "doSpellingSuggestion" );       
    call.setOperationName(new QName("urn:GoogleSearch", "doSpellingSuggestion"));       
    call.addParameter("key", XMLType.XSD_STRING, ParameterMode.IN);       
    call.addParameter("phrase", XMLType.XSD_STRING, ParameterMode.IN);       
    call.setReturnType( XMLType.XSD_STRING );       
    String ret = (String) call.invoke( new Object[] { "googlekey", doc.getDocumentDescription()} );       
    doc.setDocumentDescription(ret);
    This block of code does a very simple thing...it calls the Google "doSpellingSuggestions" web service with two parameters: a key provided by Google, and a string for which the spelling suggestions should be generated. I used the current document description as my sample string for the web service and I put the results back into the document description - remember, this is just showing how you can call the web service, not doing anything really intelligent or useful from a business perspective
    There is nothing special to E-Sourcing about the above code...this is really just using the Axis java classes to call a web service.
    The second approach that can be used is to generate Java proxies for the web service calls. The open source Axis library includes a tool called "wsdl2java". Using the WSDL for the web service, you can generate Java proxies. Java classes will be generated by the tool; these Java classes will then need to be compiled and included in E-Sourcing as a custom jar. Once they are part of the E-Sourcing deployment, they can be called like any Java API. If you were to examine the generated code, you would notice that it looks a lot like the raw web service code shown above...the generated classes really just provide a simpler interface to the same functionality.
    You can see this information and other E-Sourcing information at my blog at: http://www.sunshinesys.com/
    Rob

  • Error while calling a Web Service from a Session Bean

    I am trying to call a Web Service from a Session Bean using an Axis client, but I am getting the next exception:
    java.rmi.ServerException: RemoteException occurred in server thread; nested exception is:
         java.rmi.RemoteException: org/apache/axis/client/Service
         at com.sun.corba.ee.internal.javax.rmi.CORBA.Util.wrapException(Util.java:364)
         at javax.rmi.CORBA.Util.wrapException(Util.java:277)
         at com.ing.mx.seguros.siniestros.litigios.ejb._SisaServiceRemote_Stub.invocarWebSericeProveedorLegal(Unknown Source)
         at com.ing.mx.seguros.siniestros.litigios.proxy.SisaWsProxy.solicitarApoyoLegal(SisaWsProxy.java:132)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:402)
         at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:309)
         at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:333)
         at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:71)
         at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:150)
         at org.apache.axis.SimpleChain.invoke(SimpleChain.java:120)
         at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:481)
         at org.apache.axis.server.AxisServer.invoke(AxisServer.java:323)
         at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:854)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
         at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:339)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.catalina.core.StandardWrapperValve.invokeServletService(StandardWrapperValve.java:720)
         at org.apache.catalina.core.StandardWrapperValve.access$000(StandardWrapperValve.java:118)
         at org.apache.catalina.core.StandardWrapperValve$1.run(StandardWrapperValve.java:278)
         at java.security.AccessController.doPrivileged(Native Method)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:274)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:212)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:203)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
         at com.iplanet.ias.web.connector.nsapi.NSAPIProcessor.process(NSAPIProcessor.java:158)
         at com.iplanet.ias.web.WebContainer.service(WebContainer.java:850)Thanks for any help provided.
    Does any one have insights about it?

    Hi Swapna,
    from your screenshot it seems that you actually try to call the service in your Data Source Expression field. You should set path to the WSDL file here actually - this could be either URL to SAP or to filesystem, as Anton suggested (this could be faster). Have you created endpoint binding for your service in transaction SOAMANAGER? If yes, then simply download the corresponding WSDL with binding or copy the URL which leads to it. But also test whether you are able to retrieve the WSDL without logging into SAP (close all browser windows and then open a new one otherwise session ID from other browser windows can be reused).
    If you have to give username and password, then setup anonymous alias in transaction SICF, for example.
    Pleas, check my previous post on the same subject here: Re: BCM7 IVR : SOAP request for client identification in CRM .
    Maybe it could help.
    Regards,
    Dawood.

  • How to call COPY web service from sharepoint in SAP

    Hello Experts,
    I want to call COPY web service from SharePoint in SAP  web dynpro / JAVA application.
    However, when I try to connect to web service and download wsdl using   http:// <hostname:port>/_vti_bin/copy.asmx?wsdl
    it results in Unauthorized error and doesnt complete the setup. Detail error is :
     Error occurred while downloading WSIL file. Error message: Deserializing xml stream  http:// <hostname:port>/_vti_bin/copy.asmx?wsdl
    failed.com.sap.engine.services.webservices.espbase.wsdl.exceptions.WSDLException: Invalid Response Code: (401) Unauthorized. The requested URL was:"Connect to 
    http:// <hostname:port>/_vti_bin/copy.asmx?wsdl , used user to connect: userid"
    I am trying to connect with server user account. Any idea on what authorizations might be required or any help on the scenario .
    -Abhijeet

    Here's an example on how to delete a list item, hopefully this helps
    package com.jw.sharepoint.examples;
    import java.io.File;
    import java.text.SimpleDateFormat;
    import java.util.Calendar;
    import java.util.Date;
    import java.util.Properties;
    import org.apache.commons.logging.Log;
    import org.apache.commons.logging.LogFactory;
    import org.w3c.dom.Element;
    import org.w3c.dom.Node;
    import org.w3c.dom.NodeList;
    import com.microsoft.sharepoint.webservices.CopySoap;
    import com.microsoft.sharepoint.webservices.GetListItems;
    import com.microsoft.sharepoint.webservices.GetListItemsResponse;
    import com.microsoft.sharepoint.webservices.ListsSoap;
    import com.microsoft.sharepoint.webservices.UpdateListItems.Updates;
    import com.microsoft.sharepoint.webservices.UpdateListItemsResponse.UpdateListItemsResult;
    public class SharePointDeleteListItemExample extends SharePointBaseExample {
     private String delete = null;
     private String deleteListItemQuery = null;
     private String queryOptions = null;
     private static final Log logger = LogFactory.getLog(SharePointUploadDocumentExample.class);
     private static Properties properties = new Properties();
     public Properties getProperties() {
      return properties;
      * @param args
     public static void main(String[] args) {
      logger.debug("main...");
      SharePointDeleteListItemExample example = new SharePointDeleteListItemExample();
      try {
       example.initialize();
       CopySoap cp = example.getCopySoap();
       example.uploadDocument(cp, properties.getProperty("copy.sourceFile"));
       ListsSoap ls = example.getListsSoap();
       example.executeQueryAndDelete(ls);
      } catch (Exception ex) {
       logger.error("Error caught in main: ", ex);
     public void executeQueryAndDelete(ListsSoap ls) throws Exception {
      Date today = Calendar.getInstance().getTime();
      SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
      String formattedDate = simpleDateFormat.format(today);
      String queryFormatted = String.format(deleteListItemQuery,formattedDate);  
      GetListItems.QueryOptions msQueryOptions = new GetListItems.QueryOptions();
      GetListItems.Query msQuery = new GetListItems.Query();
      msQuery.getContent().add(createSharePointCAMLNode(queryFormatted));
      msQueryOptions.getContent().add(createSharePointCAMLNode(this.queryOptions));
      GetListItemsResponse.GetListItemsResult result = ls.getListItems(
        properties.getProperty("folder"), "", msQuery, null, "",
        msQueryOptions, "");
      writeResult(result.getContent().get(0), System.out);
      Element element = (Element) result.getContent().get(0);
      NodeList nl = element.getElementsByTagName("z:row");
      for (int i = 0; i < nl.getLength(); i++) {
       Node node = nl.item(i);
       String id = node.getAttributes().getNamedItem("ows_ID").getNodeValue();
       String fileRefRelativePath = node.getAttributes().getNamedItem("ows_FileRef").getNodeValue();
       logger.debug("id: " + id);
       logger.debug("fileRefRelativePath: " + fileRefRelativePath);
       String fileRef = properties.getProperty("delete.FileRef.base") + fileRefRelativePath.split("#")[1];
       logger.debug("fileRef: " + fileRef);
       deleteListItem(ls, properties.getProperty("folder"), id, fileRef);
     public void deleteListItem(ListsSoap ls, String listName, String listId, String fileRef) throws Exception {
      String deleteFormatted = String.format(delete, listId, fileRef);  
      Updates u = new Updates();
      u.getContent().add(createSharePointCAMLNode(deleteFormatted));
      UpdateListItemsResult ret = ls.updateListItems(listName, u);
      writeResult(ret.getContent().get(0), System.out);
     public void initialize() throws Exception {
      logger.info("initialize()...");
      properties.load(getClass().getResourceAsStream("/SharePointDeleteListItemExample.properties"));
      super.initialize();
      this.delete = new String(readAll(new File(this.getClass().getResource("/Delete.xml").toURI())));
      this.deleteListItemQuery = new String(readAll(new File(this.getClass().getResource("/DeleteListItemQuery.xml").toURI())));
      this.queryOptions = new String(readAll(new File(this.getClass().getResource("/QueryOptions.xml").toURI())));
    Brandon James SharePoint Developer/Administrator

  • How can I call external web service from BPEL

    1. I have "EmpService" webservice (simple webservice to get emp salary, not in BPEL domain) running in Oracle AS host1. If I want to call this web service from BPEL in another host2. How can I do this?
    2. Is it a must to deploy this EmpService to Oracle BPEL domain in order to call it? If so, how can I deploy it. As many BPEL example tutorial demonstrate the "obant" command to deploy the BPEL process, but not show how to deploy a external web service not in BPEL project. Please help. ...

    Create a partner link in BPEL and point it to the WSDL deployed on external server.
    this thread will also help
    Axis generated WS to Bpel WS

  • Calling a Web Service from Java

    Our java guru (who is out sick....AHHHH) created all the calls that are needed to access the web service that he has running. For example the call getLongList(String user, String password) will return a list of all outstanding transactions. He made a jar file that has service has class files for PortType, Service, Service Locator and Soap Binding stub.
    How do I call this web service from java? Do I have to import it into my classpath? or just call these parameters from within my java code?

    never mind...i got it

  • Calling a Web Service from Mobile - UI options

    Hi Team,
    I have a scenario where the backend SAP functionality is exposed as a web service and we need to call it online from a mobile handheld device (Symbol with Pocket PC client 2003, IE browser 4.0). Is it possible to call this web service from the handheld? Do we have to write the web service call on the J2EE stack using NetWeaver developer studio?
    Also, what UI technology is recommended for showing the data from the web service call. The idea is to get some user input on the handheld, and then post a transaction via the web service on SAP. I discussed with some of my colleagues and they recommend to use JSP/Servlets for this. Does anybody has a better idea, (the JSP/Servlets does not seem correct). Should we use native XSLT or something else.
    Please note that the Mobile Web Dynpro has limitations on the UI side and the "onEnter", "setFocus" does not work, specifically on the netweaver 2004s release. The backend ERP system we have is 2004s and I'm trying to make a web service call from a NW 2004 client.
    Any ideas or pointers will be appreciated and points awarded. Thanks for your time.

    Hi Sanjay!
    Yes, To call a WebService you will have to write your Own Application using NWDS.I donot have any specific recommendation for the UI Technology to be used.
    Usage of "OnEnter" and "SetFocus" with NW2004s has certain limitations below.
    "OnEnter" is not a supported feature as of now especially for WD applications on Handheld Devices.
    "SetFocus" will work on IE6.0 Standard Desktop Browser with WAS7.0 SP06 and i believe it will work in hand held devices if your using WAS7.0(NW2004s)SP8 and you are using the latest Symbol Device that has Windows Mobile 5.0 OR Windows CE.NET 5.0.I understand that there could be some limitations with the OS and the IE you are currently running in the device.
    Let me know your views.
    Thank You
    Gisk

  • Calling a Web Service from Java Webdynpro

    Hi,
    Can any one give me step by setp details on how to call a Web Service from Java Webdynpro ?
    I tried creating a model using Import Web Service Model but when I completed creating the model, I got some errors as shown below.
    Error               The method setRouteGeometryLineArray(double[][]) in the type Trip is not applicable for the arguments (double[])     ComplexType_Trip.java     WS_INVOKE/gen_wdp/packages/com/cintas/test/model/p1     line 249
    thanks
    SBK

    Hi SBK,
    I assume you may already have read the [help guide|http://help.sap.com/saphelp_nw70/helpdata/EN/81/12703e5da3e946e10000000a114084/content.htm] This gives a pretty good idea of how to do it (step by step).
    Is there a typo in the error you pasted?
    Error The method setRouteGeometryLineArray(double][) in the type Trip is not applicable for the arguments (double[]) ComplexType_Trip.java WS_INVOKE/gen_wdp/packages/com/cintas/test/model/p1 line 249
    The square brackets [] after double in the method call appear to be reversed. Is that also in the code? or just a mistake here?
    Hope this points you in the right direction.
    BRgds,
    Simon

  • Calling a Web Service from forms

    Hello,
    I'm trying to call a web service from within forms (10gR2). I have generated a stub from the wsdl via jdeveloper, and imported the appropriate classes to my form. My problem is that the webservice requires 2 java objects passed to it. The first is a simply "row" structured object which is no problem, but the second object is an array of "record structures". I have created a pl/sql table of ora_java.jarray and populated the elements and rows of this table accordingly (using the java classes generated), but I have no knowledge of how to convert this pl/sql table to the java object that is to be passed to the web service. Could anyone propose a solution? Any help would be greatly appreciated.
    Regards,
    Robert

    The java generated provides the following classes
    hdrobjuser1 which is a structure consisting of string, string, decimal, string, date, string (the first parameter of the webservice call),
    dtlobjuser1 which is a structure consisting of string, string, decimal, string, string, string, decimal
    dtlobj1 which is an array of dtlobjuser1 (the second parameter of the webservice call)
    The problem is that I have methods to generate and populate both the hdrobjuser1 and dtlobjuser1 classes, but there is no method that I can use to create array elements within the dtlobj1 array

  • Calling a web service from BPM without using bridge S/A

    Hi Experts,
    I want to call a web service from a BPM and I want to call it asyncronously. That is by having my request and my response as a separate interface.
    I already did it by calling another BPM, this one with a bridge, but I don't like this solution.
    Any ideas?
    Regards
    Gonzalo

    Hi Sanjeev,
    EDIT: I was wrong, I have to reconsider your scenario.
    Leela,
    Watch this:
    http://img74.imageshack.us/img74/3536/presentacin2vm9.jpg
    The points of my scenario:
    -There's a BPM
    -Send and Receive in BPM have to be asynchronous
    -It have to comunicate with a WS wich is synchronous
    -I thought that, may be, playing with the receiver SOAP adapter modules I will achieve to send the response to another SOAP adapter, a sender one, and then have my ASYNC/SINC scenario as it's described here: File - RFC - File without a BPM - Possible from SP 19.
    Regards
    Gonzalo
    Edited by: Gonzalo del Castillo on Nov 20, 2008 11:29 AM

Maybe you are looking for