Return NULL when invoke Web Service via UTL_DBWS

Hi all,
right now, i'm using UTL_DBWS to acces Web Service via database.. but when i'm trying to get data from WEB SERVICE, using utl_dbws.invoke , i got NULL value.
It happened if The result more than Varchar2 / 32767 byte.
i'have tried to change code by :
result := sys.utl_dbws.invoke(l_call, l_input_params);
P_clob := sys.anydata.accessCLOB(result);
The Output IS NULL value even if the data was less than Varchar2 or 32767 byte..
this is my script looks like ::
declare
service sys.utl_dbws.SERVICE;
l_call sys.utl_dbws.CALL;
result ANYDATA;
wsdl_url VARCHAR2(1024);
service_name VARCHAR2(200);
operation_name VARCHAR2(200);
input_params sys.utl_dbws.ANYDATA_LIST;
p_out VARCHAR2(32767);
p_xml XMLTYPE;
p_clob CLOB;
begin
wsdl_url := 'http://127.0.0.1/Exercise/WSDL2.php?wsdl';
service_name :='{urn:hellowsdl}hellwsdl';
operation_name := 'getData';
service := sys.UTL_DBWS.create_service (
wsdl_document_location => URIFACTORY.getURI(wsdl_url),
service_name => service_name);
l_call := sys.utl_dbws.create_call(
service_handle => service,
port_name => null,
operation_name => operation_name
input_params(1) := ANYDATA.ConvertVarchar2('DOCCODE');
result := sys.utl_dbws.invoke(l_call, l_input_params);
p_out := sys.anydata.accessVarchar2(result);
sys.UTL_DBWS.release_call (call_handle => l_call);
sys.UTL_DBWS.release_service (service_handle => service);
end;
Thanx for Any Help

The basics are simple:
- format a valid SOAP envelope
- use UTL_HTTP to make the call
- process the response (typically XML output)
Sample source code in {message:id=4205205}.

Similar Messages

  • "Error while parsing SOAP XML payload: no element found" received when invoking Web Service

    Running PB 12.1 Build 7000.  Using Easysoap.  Error ""Error while parsing SOAP XML payload: no element found" received when invoking Web Service".  This error does not appear to be coming from the application code.  Noticed that there were some erroneous characters showing up within the header portion of the XML ("&Quot;").  Not sure where these are coming from.  When I do a find within the PB code for """" it gets located within two objects, whereas they both reference a "temp_xml_letter".  Not sure where or what temp_xml_letter resides???   The developer of this is no longer with us and my exposure to WSDL and Web Services is rather limited.  Need to get this resolved...please.
    This is the result of the search.  Notice the extraneous characters ("""):
    dar1main.pbl(d_as400_mq_xml)
    darlettr.pbl(d_email_xml)
    ---------- Search: Searching Target darwin for 'temp_xml'    (9:52:41 AM)
    ---------- 2 Matches Found On "temp_xml":
    dar1main.pbl(d_as400_mq_xml).d_as400_mq_xml:  export.xml(usetemplate="temp_xml_letter" headgroups="1" includewhitespace="0" metadatatype=0 savemetadata=0  template=(comment="" encoding="UTF-8" name="temp_xml_letter" xml="<?xml version=~"1.0~" encoding=~"UTF-16LE~" standalone=~"yes~"?><EmailServiceTransaction xmlns=~"http://xml.xxnamespace.com/Utility/Email/EmailService" ~" xmlns:imc=~"http://xml.xxnamespace.com/IMC~" xmlns:xsi=~"http://www.w3.org/2001/XMLSchema-instance~" xmlns:root=~"http://xml.xxnamespace.com/RootTypes~" xmlns:email=~"http://xml.xxnamespace.com/Utility/Email~" xsi:schemaLocation=~"http://xml.xxnamespace.com/Utility/Email/EmailService http://dev.xxnamespace.com/Utility/Email/EmailService/V10-TRX-EmailService.xsd~"><EmailServiceInformation><EmailServiceDetail __pbband=~"detail~"><ApplicationIdentifier> applicationidentifier </ApplicationIdentifier><AddresseeInformation><AddresseeDetail><Number> number </Number></AddresseeDetail></AddresseeInformation><EmailMessageInformation><Ema
    darlettr.pbl(d_email_xml).d_email_xml:  export.xml(usetemplate="temp_xml_letter" headgroups="1" includewhitespace="0" metadatatype=0 savemetadata=0  template=(comment="" encoding="UTF-8" name="temp_xml_letter" xml="<?xml version=~"1.0~" encoding=~"UTF-16LE~" standalone=~"yes~"?><EmailServiceTransaction xmlns=~"http://xml.xxnamespace.com/Utility/Email/EmailService" ~" xmlns:imc=~"http://xml.xxnamespace.com/IMC~" xmlns:xsi=~"http://www.w3.org/2001/XMLSchema-instance~" xmlns:root=~"http://xml.xxnamespace.com/RootTypes~" xmlns:email=~"http://xml.xxnamespace.com/Utility/Email~" xsi:schemaLocation=~"http://xml.xxnamespace.com/Utility/Email/EmailService http://dev.xxnamespace.com/Utility/Email/EmailService/V10-TRX-EmailService.xsd~"><EmailServiceInformation><EmailServiceDetail __pbband=~"detail~"><ApplicationIdentifier> applicationidentifier </ApplicationIdentifier><AddresseeInformation><AddresseeDetail><Number> imcnumber </Number></AddresseeDetail></AddresseeInformation><EmailMessageInformation><Ema
    ---------- Done 2 Matches Found On "temp_xml":
    ---------- Finished Searching Target darwin for 'temp_xml'    (9:52:41 AM)

    Maybe "extraneous" is an incorrect term.  Apparantly, based upon the writeup within Wiki, the parser I am using does not interpret the "&quot;"?  How do I find which parser is being utilized and how to control it?
    <<<
    If the document is read by an XML parser that does not or cannot read external entities, then only the five built-in XML character entities (see above) can safely be used, although other entities may be used if they are declared in the internal DTD subset.
    If the document is read by an XML parser that does read external entities, then the five built-in XML character entities can safely be used. The other 248 HTML character entities can be used as long as the XHTML DTD is accessible to the parser at the time the document is read. Other entities may also be used if they are declared in the internal DTD subset.
    >>>

  • "Binding is null" when calling web service

    Hello,
    I'm trying to call a web service from an automatic activity using:
    str as String
    hw as RecupelWebServices.HelloWorld.DummyWebService = MyWebServices.HelloWorld.DummyWebService()
    helloWorld hw
         returning str = helloWorldResult
    (similar to the documentation example)
    But it fails, warning that:
    a component failed trying to execute activity ...
    The method 'CIL_myMethod' from class 'MyProject.MyProcessName.Default_1_0.Instance' could not be successfully executed.
    Caused by: Binding is null, maybe this web service was introspected with an old version. Try to reintrospect it.
    fuego.lang.ComponentExecutionException: The method 'CIL_myMethod' from class 'MyProject.MyProcessName.Default_1_0.Instance' could not be successfully executed.
    Introspection went ok, although with a warning:
    Introspecting...
    downloading /DummyWebService/HelloWorld.asmx?wsdl
    parsing /DummyWebService/HelloWorld.asmx?wsdl
    checking /DummyWebService/HelloWorld.asmx?wsdl
    [Warning] The binding 'DummyWebServiceSoap12' with type 'tns:DummyWebServiceSoap'is unsupported. Components will not be generaded for this binding..
    'http://tempuri.org/' was parsed.
    Analyzing dependecies for module 'MyWebServices.HelloWorld'...
    Analyzing dependecies for module 'MyWebServices.HelloWorld'...
    Analyzing Components
    Storing Instrospected Types
    Introspection completed. Errors: 0, Warnings: 1.
    The web service is also accessible outside of the BPM environment.
    Any ideas what I'm missing here?

    I'm having the same issue with OBPM Studio 10.3.1 build #98887 when trying to invoke a Web Service introspected from OSB.
    Caused by: Binding is null, maybe this web service was introspected with an old version. Try to reintrospect it.
    When introspecting I got one warning that doesn't seem to have any relation with the runtime error:
    +[Warning] It is not recommended the usage of SOAP encoding array types, specially if you are working with document/literal WSDLs (complex type name: List in namespace: java:java.util ).+

  • Wrong data when consuming web service via ABAP

    Dear all,
    we tried to consume a web service via ABAP and used one of the various existing how-to papers from the internet in order to develop everything.
    The development was not that difficult, but when we now execute our ABAP, we noticed that
    - the first 100 returned rows from the webservice are completely correct
    - then we receive 10-15 completely incorrect rows (empty fields, redundant lines, etc.)
    - the rest of the data (60 records) is correct again
    As we nearly all objects have been generated automatically via SE80, I do not really know where this problem might come from. We double checked the original data and there everything is correct.
    Any ideas?
    Thanks for your feedback,
    Andreas

    Marcelo  Almeida wrote:
    > You can use Logial port for it in LPCONFIG ( Transaction). See this examplo Below:
    >
    > TRY.
    >
    > CREATE OBJECT my_proxy
    > EXPORTING
    > logical_port_name = 'LP01'.
    > CATCH cx_ai_system_fault.
    > ENDTRY.
    >
    > TRY.
    > input-airline_id = p_carrid.
    > input-connection_id = p_connid.
    > input-flight_date = p_fldate.
    >
    > CALL METHOD my_proxy->flight_get_detail
    > EXPORTING
    > input = input
    > IMPORTING
    > output = output.
    > CATCH cx_ai_system_fault.
    > CATCH cx_ai_application_fault.
    > ENTRY.
    >
    > Its necessary create a connection in SM59 (type H) and setting in the call parameters logical port (LPCONFIG).
    Hi,
    thanks for your answer. It´s working!
    Cheers,
    Andy

  • Connection Reset Error, When invoking Web Services

    I'm trying to invoke a web service using 'Invoke Web Service' Operation. Its works for 8 out of 10 times. Sometime it stalled with "Conneciton Reset' error.
    When retry this stalled action from AdminUI, its works fine.
    Can someone advise on this issue?
    I have attached the error log for reference.
    Thanks,
    Nith

    If you attempt to retry the stalled component through adminui, it will work. Am i correct?
    If so, you can test the following approach.
    1. drag a blank component (e.g a decision point)
    2. connect a line between the exception of the Web Service Invoke operation to the decision point.
    3. Choose java.io.IOException from the eeception drop down.
    4. again connect the decision point back to the web service invoke component. (i mean a looping)
    This approach was working fine with me.
    Please see the attached image shows my routing.
    PS: After a couple of days, I tested without looping and it seems to be working. So I removed the loop now.
    Thanks,
    Nith

  • Calling web service via utl_dbws with unbounded return values

    Hello, everyone.
    I'm trying to use utl_dbws to call web service from Oracle DB 10 g.
    WS has unbounded return value:
    <xs:element maxOccurs='unbounded' minOccurs='0' name='return' type='xs:string'/>
    I'm setting return paramter in web service call handler like this:
    sys.UTL_DBWS.set_return_type(l_h_service_call, cs_qname_type_string);
    and when I'm trying to call it from PL/SQL function I'm getting an error:
    ORA-29532: Java call terminated by uncaught Java exception:
    deserialization error: XML reader error: unexpected character content: "s2"
    ORA-06512: at "SYS.UTL_DBWS", line 388
    ORA-06512: at "SYS.UTL_DBWS", line 385
    ORA-06512: at line 38
    I've tried to return values by out parameters and got the same exception.
    It looks like utl_dbws needs to know parameters count before calling.
    Have anyone succeded in getting arrays from Web Service call?
    This is a part of wsdl:
    <xs:complexType name='getProcessList'>
    <xs:sequence>
    <xs:element minOccurs='0' name='nameMask' type='xs:string'/>
    </xs:sequence>
    </xs:complexType>
    <xs:complexType name='getProcessListResponse'>
    <xs:sequence>
    <xs:element maxOccurs='unbounded' minOccurs='0' name='return' type='xs:string'/>
    </xs:sequence>
    </xs:complexType>
    Throught SoapUI I can produce such kind of request:
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:proc="http://processmanager.argustelecom.ru/">
    <soapenv:Header/>
    <soapenv:Body>
    <proc:getProcessList>
    <processNameMask>*</processNameMask>
    </proc:getProcessList>
    </soapenv:Body>
    </soapenv:Envelope>
    and get a response:
    <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
    <env:Header/>
    <env:Body>
    <ns2:getProcessListResponse xmlns:ns2="http://processmanager.argustelecom.ru/">
    <return>s1</return>
    <return>s2</return>
    <return>s3</return>
    <return>s4</return>
    </ns2:getProcessListResponse>
    </env:Body>
    </env:Envelope>
    PL/SQL function:
    DECLARE
    cs_qname_type_string CONSTANT sys.UTL_DBWS.qname
    := sys.UTL_DBWS.to_qname('http://www.w3.org/2001/XMLSchema', 'string') ;
    cs_qname_type_int CONSTANT sys.UTL_DBWS.qname := sys.UTL_DBWS.to_qname('http://www.w3.org/2001/XMLSchema', 'int');
    cs_qname_type_any CONSTANT sys.UTL_DBWS.qname
    := sys.UTL_DBWS.to_qname('http://www.w3.org/2001/XMLSchema', 'anyType') ;
    cs_endpoint CONSTANT VARCHAR2(256) := 'http://server:8080/process-manager/ProcessManager';
    l_service sys.UTL_DBWS.service;
    l_service_qname sys.UTL_DBWS.qname;
    l_port_qname sys.UTL_DBWS.qname;
    l_operation_qname sys.UTL_DBWS.qname;
    l_h_service_call sys.UTL_DBWS.call;
    l_params sys.UTL_DBWS.anydata_list;
    l_ret_val SYS.ANYDATA;
    BEGIN
    l_service_qname := sys.UTL_DBWS.to_qname(NULL, 'ProcessManagerService');
    l_service := sys.UTL_DBWS.create_service(l_service_qname);
    l_port_qname := sys.UTL_DBWS.to_qname(NULL, 'ProcessListServiceBinding');
    l_operation_qname := sys.UTL_DBWS.to_qname('http://processmanager.argustelecom.ru/', 'getProcessList');
    l_h_service_call := sys.UTL_DBWS.create_call(l_service, l_port_qname, l_operation_qname);
    sys.UTL_DBWS.set_target_endpoint_address(l_h_service_call, cs_endpoint);
    -- return type
    sys.UTL_DBWS.set_return_type(l_h_service_call, cs_qname_type_any);
    -- param type
    sys.UTL_DBWS.ADD_PARAMETER(l_h_service_call, 'processNameMask', cs_qname_type_string, 'ParameterMode.IN');
    l_params(1) := anydata.convertvarchar2('*');
    l_ret_val := sys.UTL_DBWS.invoke(l_h_service_call, l_params);
    IF l_ret_val IS NULL THEN
    DBMS_OUTPUT.put_line('l_ret_val is null');
    ELSE
    DBMS_OUTPUT.put_line('l_ret_val is not null');
    END IF;
    sys.UTL_DBWS.release_call(l_h_service_call);
    END;
    Edited by: Ilya on 03.12.2008 3:50

    Hi Tony
    I'm not sure if you would have solved your problem by now, but with my recent experience with the utl_dbws package, for doc lits with complex data types, you have to call the service with an XML request, as opposed to passing the param array.
    If you still need details, reply accordingly.
    Ta
    cT

  • Extracting Tag Value from XML returned when a web service via PL/SQL

    All,
    Good afternoon.
    I have a PL/SQL that called a web service. The code is as below:
    create or replace procedure soap3 as
    soap_request varchar2(30000);
    soap_respond varchar2(30000);
    http_req utl_http.req;
    http_resp utl_http.resp;
    resp XMLType;
    i integer;
    bra number := 205;
    cus number := 134988;
    cur number := 1;
    led number := 0;
    sub number := 0;
    chq number := 1;
    n number;
    v_raw RAW(32767);
    buff RAW(32767);
    http_res UTL_HTTP.resp;
    blob_length INTEGER;
    chunk_size BINARY_INTEGER := 32767;
    blob_position INTEGER := 1;
    out_file UTL_FILE.FILE_TYPE;
    name VARCHAR2(256);
    value VARCHAR2(1024);
    v_buffer RAW(32767);
    begin
    soap_request := '<?xml version="1.0" encoding="utf-8"?>
    <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
    <soap:Body>
    <Validate_Mandate xmlns="http://tempuri.org/Clearing_Workflow/Service1">
    <Bra_code>205</Bra_code>
    <Cus_num>134988</Cus_num>
    <Cur_code>0</Cur_code>
    <Led_code>0</Led_code>
    <sub_acct_Code>0</sub_acct_Code>
    </Validate_Mandate>
    </soap:Body>
    </soap:Envelope>';
    --DBMS_LOB.CREATETEMPORARY(buff,true);
    http_req := utl_http.begin_request('http://10.99.0.13/clearinginwards/InwardCheques.asmx',
    'POST',
    'HTTP/1.1');
    utl_http.set_header(http_req, 'Content-Type', 'text/xml'); -- since we are dealing with plain text in XML documents
    utl_http.set_header(http_req, 'Content-Length', length(soap_request));
    utl_http.set_header(http_req,
    'SOAPAction',
    'http://tempuri.org/Clearing_Workflow/Service1/Validate_Mandate'); -- required to specify this is a SOAP communication
    utl_http.write_text(http_req, soap_request);
    http_resp := utl_http.get_response(http_req);
    dbms_output.put_line('HTTP response status code: ' || http_resp.status_code);
    dbms_output.put_line('HTTP response reason phrase: ' || http_resp.reason_phrase);
    UTL_HTTP.read_raw(http_resp, buff, 32767);
    end;
    The response gotten from the web service is as below :
    open=F, temp=T, length=13256, chunksize=8132, data=3C3F786D6C2076657273696F6E3D22312E302220656E636F64696E673D227574662D38223F3E3C736F61703A456E76656C6F706520786D6C6E733A736F61703D22687474703A2F2F736368656D61732E786D6C736F61702E6F72672F736F61702F656E76656C6F70652F2220786D6C6E733A7873693D22687474703A2F2F7777772E77332E6F72672F323030312F584D4C536368656D612D696E7374616E63652220786D6C6E733A7873643D22687474703A2F2F7777772E77332E6F72672F323030312F584D4C536368656D61223E3C736F61703A426F64793E3C56616C69646174655F4D616E64617465526573706F6E736520786D6C6E733D2268747470
    I do not understand what this output actually means as what the webservice returns is meant tio be a XML with a signature tag that contain an image of customers signature.
    Please I need help.

    Thanks for the responses thus far , but I think i need to properly define my problem so will be able to help me better.
    I have a webservice with the definition below :
    POST /NigMailService/nigmailservice.asmx HTTP/1.1
    Host: 10.2.15.157
    Content-Type: text/xml; charset=utf-8
    Content-Length: length
    SOAPAction: "http://tempuri.org/GetImageDataTable_HT"
    <?xml version="1.0" encoding="utf-8"?>
    <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
    <soap:Body>
    <GetImageDataTable_HT xmlns="http://tempuri.org/">
    <BranchCode>int</BranchCode>
    <CustomerNumber>int</CustomerNumber>
    <CurrencyCode>int</CurrencyCode>
    <LedgerCode>int</LedgerCode>
    <SubAccountCode>int</SubAccountCode>
    <ChequeNumber>int</ChequeNumber>
    <ClientCode>string</ClientCode>
    <wantedImageTypes>int</wantedImageTypes>
    <wantedImageSize_InPercent>int</wantedImageSize_InPercent>
    </GetImageDataTable_HT>
    </soap:Body>
    </soap:Envelope>
    and sample response :
    HTTP/1.1 200 OK
    Content-Type: text/xml; charset=utf-8
    Content-Length: length
    <?xml version="1.0" encoding="utf-8"?>
    <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
    <soap:Body>
    <GetImageDataTable_HTResponse xmlns="http://tempuri.org/">
    <GetImageDataTable_HTResult>xmlxml</GetImageDataTable_HTResult>
    </GetImageDataTable_HTResponse>
    </soap:Body>
    </soap:Envelope>
    My aim is to write a PL/SQL that will call the webservice and recieve the response which is definately a XML with an image that is meant to be written to a file in PL/SQL.
    Please how can i achieve this ?

  • Unable to call a Web Services via UTL_DBWS

    Hi all,
    I create with Apex 3.1 a web service (it works)
    Now i need to use the UTL_DBWS package to access a web services from PL/SQL
    So i get the Name 'WebServiceDemo', the URL 'http://my_url' and the Target Namespace 'http://my_target'
    from the web service reference to build PL/SQL process
    The operation 'Login' has two input parameters (username as string, password as string - nullable)
    and one ouput parameter (sessionId as string)
    When i run the following source code, i get an error
    ORA-29532: javax.xml.rpc.soap.SOAPFaultException: Well-formedness violation
    Oracle 10.2.0.4
    What am i doing wrong?
    Any help is appreciated,
    Thanks
    Grégory
    Here is my code :
    DECLARE
       service_            UTL_DBWS.service;
       call_               UTL_DBWS.CALL;
       service_qname       UTL_DBWS.qname;
       port_qname          UTL_DBWS.qname;
       operation_qname     UTL_DBWS.qname;
       string_type_qname   UTL_DBWS.qname;
       retx                ANYDATA;
       retx_string         VARCHAR2 (100);
       retx_len            NUMBER;
       params              UTL_DBWS.anydata_list;
    BEGIN
       service_qname := UTL_DBWS.to_qname (NULL, 'WebServiceDemo');
       service_ := UTL_DBWS.create_service (service_qname);
       port_qname := UTL_DBWS.to_qname (NULL, 'WebServiceDemo');
       -- target --
       operation_qname := UTL_DBWS.to_qname ('http://my_target', 'Login');
       call_ := UTL_DBWS.create_call (service_, port_qname, operation_qname);
       -- URL --
       UTL_DBWS.set_target_endpoint_address
          (call_,
           'http://my_url'
       string_type_qname :=
                  UTL_DBWS.to_qname ('http://www.w3.org/2001/XMLSchema', 'string');
       UTL_DBWS.ADD_PARAMETER (call_,
                               'name',
                               string_type_qname,
                               'ParameterMode.IN'
       UTL_DBWS.set_return_type (call_, string_type_qname);
       params (0) := ANYDATA.convertvarchar2 ('my_login');
       retx := UTL_DBWS.invoke (call_, params);
       retx_string := retx.accessvarchar2;
    END;

    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

  • Java exception when invoking web service

    I am using JDeveloper 10.1.3.04 to deploy a PL/SQL function as a web service to 10gIAS. I can deploy the service, but when invoking it from the endpoint my SOAP output looks like this:
    <?xml version="1.0" encoding="UTF-8" ?>
    - <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    - <SOAP-ENV:Body>
    - <SOAP-ENV:Fault>
    <faultcode>SOAP-ENV:Server.Exception:</faultcode>
    <faultstring>java.lang.NullPointerException</faultstring>
    <faultactor>/GetAmountContextRoot/MyWebService1</faultactor>
    </SOAP-ENV:Fault>
    </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
    Deploying what is essentially the same web service to the OC4J instance that comes with JDeveloper, my SOAP returns the expected value:
    <?xml version="1.0" encoding="UTF-8"?>
    <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns0="http://devl29ieda/MyWebService2.wsdl/types/"><env:Body><ns0:returnAmountResponseElement><ns0:result>305249</ns0:result></ns0:returnAmountResponseElement></env:Body></env:Envelope>
    I believe the problem is within the Java code created by the Web Service Wizard, but I do not know where.
    Any help would be greatly appreciated.
    Steven

    Hi Steven,
    You may want to look at the log on the server side to see if you have any hint that may help you track down where the NPE is comming from.
    As you are using PL/SQL function, the other think you want to check is that the datasource information are properly defined in both environment.
    Hope it helps,
    -eric

  • Java.sql.SQLException: Closed Connection error when invoking web service

    Hi
    I've assembled a simple web service for an Oracle PL/SQL package and deployed it on a Standalone OC4J, when I come to invoke it on the Oracle Enterprise Manager screen I'm getting the following returned within the envelope body:
    <env:Body>
    <env:Fault>
    <faultcode>env:Server</faultcode>
    <faultstring>Internal Server Error (serialization error: java.sql.SQLException: java.sql.SQLException: Closed Connection)</faultstring>
    </env:Fault>
    </env:Body>
    The function that is called within the database returns a user defined object that consists of a RAW value and an XMLTYPE. The function takes a string as a parameter, when I enter a string that I know will not return an object there is no error in the envelope body, only when there is an object to return does the error appear.
    Anyone have any suggestion as to why this is?

    I'm no further forward with this: has anyone assembled, deployed and invoked a web service that returns a XMLTYPE?? I know this should be possible but I think there's maybe some manual intervention required with the classes created with webservicesassembler: I'd really appreciate it if anyone with any experience of this kind of thing could help me think this through.

  • Proxy Error When Invoking Web Service

    Hi all,
    i created a web service from a session bean,
    when i invoke the web service from my web browser it works great,
    but when i try to invoke it from a bpel process, i get the following error in the Invoke Activity:
    when invoking endpointAddress 'http://10.0.1.159:8989/EJB-Application2-Model-context-root/updatePayloadServiceSoapHttpPort', (502)Proxy Error ( The ISA Server denied the specified Uniform Resource Locator (URL). )
    any idea what to do to resolve this issue?
    thanks

    It seems that your proxy server refuses serve requests for your private network (10.0.x.x).
    Try to turn off proxy server in your BPEL. In devel server turn off proxy (or add this address to exceptions) in <ORAHOME>\integration\orabpel\bin\obsetenv.bat
    and if you are using full AS, go to EM a change parameters for these server properties:
    -Dhttp.proxySet=true
    -Dhttp.proxyHost=yourproxy
    -Dhttp.proxyPort=proxyport
    -Dhttp.nonProxyHosts=10.0.1.159|and rest of your exceptions
    Peter

  • German Characters issue while invoking Web Services via UTL_HTTP

    Dear Forum Members,
    I'm trying to invoke SAP CRM Web services from Oracle PL/SQL. I have used following code which is working fine.
    -- call web service using Oracle UTIL_HTTP packages
    DECLARE
      http_req utl_http.req;
         http_resp utl_http.resp;
         lv_request VARCHAR2(32767);
         lc_response CLOB;
         lv_buffer VARCHAR2(32000);
         lv_name          VARCHAR2(256);
         lv_hdr_value     VARCHAR2(1024);     
         l_xml XMLType;          
    BEGIN     
         utl_http.set_persistent_conn_support(true);
         utl_http.set_transfer_timeout(600);
         http_req:= utl_http.begin_request
                                       ( url => 'http://xyz3ni92.server.xyz.com:8045/sap/bc/srt/xip/sap/crm_bupa_custid_qr/011/customersbycrmid/http_binding'
                                       , method => 'POST'                              
         lv_request := '<?xml version="1.0" encoding="UTF-8"?>'
         ||'<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:glob="http://sap.com/xi/CRM/Global2">'
       ||'<soap:Header/>'
       ||'<soap:Body>'
          ||'<glob:CustomerCRMByIDQuery>'
             ||'<MessageHeader>'
                ||'<ID schemeID="?" schemeAgencyID="?" schemeAgencySchemeAgencyID="?"></ID>'
                ||'<UUID></UUID>'
                ||'<ReferenceID schemeID="?" schemeAgencyID="?" schemeAgencySchemeAgencyID="?"></ReferenceID>'
                ||'<ReferenceUUID></ReferenceUUID>'
             ||'</MessageHeader>'
             ||'<BusinessPartnerSelectionByBusinessPartner>'
                ||'<UUID schemeID="?" schemeAgencyID="?"></UUID>'
                ||'<InternalID>2200117598</InternalID>'
             ||'</BusinessPartnerSelectionByBusinessPartner>'
          ||'</glob:CustomerCRMByIDQuery>'
               ||'</soap:Body>'
         ||'</soap:Envelope>';     
         /*set username and password*/
         utl_http.set_authentication (
                   r => http_req,
                   username => 'WS_USER',
                   password => 'WS_PASSWORD',
                   scheme => 'Basic',
                   for_proxy => false);     
         utl_http.set_header(http_req, 'Content-Type', 'application/soap+xml;charset=UTF-8');
         utl_http.set_header(http_req, 'Content-Length', LENGTHB(lv_request));
         utl_http.write_text(http_req, lv_request);
         /*Make HTTP call*/
         http_resp:= utl_http.get_response(http_req);
         /*read response text from response*/
         BEGIN
                   LOOP
                             utl_http.read_text(http_resp, lv_buffer);
                             lc_response := lc_response || TO_CLOB(lv_buffer);
                   END LOOP;
         EXCEPTION
                   WHEN OTHERS THEN
                        -- ora-29266 end-of-body reached
                        IF SQLCODE <> -29266 THEN
                                  RAISE;
                        END IF;
         END;
         utl_http.end_response(http_resp);     
         l_xml := XMLType(lc_response);
         /*Log response for testing*/
         DELETE FROM webservice_log;
         INSERT INTO webservice_log (seq_id,xml_response) VALUES (sqe_Webservice_Log.NEXTVAL,l_xml);
    EXCEPTION WHEN OTHERS THEN
              RAISE;
    END;However, if there are any German Characters in SAP, then they are being replaced by JUNK data when they come to Oracle.
    If I invoke the same web-service suing tools like SOAP-UI, then German characters are coming fine. I have also traced web-service requests/responses from SAP side, and there response is showing fine. When it comes to Oracle, they are getting corrupted.
    I'm sure it's something to do with character-set, but I'm not able to find-out where and what I should fix/change.
    Thanks for your help in advance.
    DB: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    NLS_DATABASE_PARAMETERS
    PARAMETER                      VALUE                                 
    NLS_LANGUAGE                   AMERICAN                                
    NLS_TERRITORY                  AMERICA                                 
    NLS_CURRENCY                   $                                       
    NLS_ISO_CURRENCY               AMERICA                                 
    NLS_NUMERIC_CHARACTERS         .,                                      
    NLS_CHARACTERSET               AL32UTF8                                
    NLS_CALENDAR                   GREGORIAN                               
    NLS_DATE_FORMAT                DD-MON-RR                               
    NLS_DATE_LANGUAGE              AMERICAN                                
    NLS_SORT                       BINARY                                  
    NLS_TIME_FORMAT                HH.MI.SSXFF AM                          
    NLS_TIMESTAMP_FORMAT           DD-MON-RR HH.MI.SSXFF AM                
    NLS_TIME_TZ_FORMAT             HH.MI.SSXFF AM TZR                      
    NLS_TIMESTAMP_TZ_FORMAT        DD-MON-RR HH.MI.SSXFF AM TZR            
    NLS_DUAL_CURRENCY              $                                       
    NLS_COMP                       BINARY                                  
    NLS_LENGTH_SEMANTICS           BYTE                                    
    NLS_NCHAR_CONV_EXCP            FALSE                                   
    NLS_NCHAR_CHARACTERSET         AL16UTF16                               
    NLS_RDBMS_VERSION              11.2.0.1.0   Regards,
    Hari
    added further details by: Hari_639 on Apr 24, 2013 6:45 PM

    Hello Both,
    Thank you.
    I ran following command from SQL Plus window after connecting to DB..
    SQL> @[%NLS_LANG%]
    SP2-0310: unable to open file "[AMERICAN_AMERICA.WE8MSWIN1252]"And also I have checked actual data using DUMP function, it looks like data stored is wrong.
    I have updated one field in SAP such that it only contains German character ä. When I query corresponding data from Oracle I got following output..
    SELECT xmlresponse.Notes,
      dump(xmlresponse.Notes,1010) dump_text
    FROM webservice_log,
      Xmltable(Xmlnamespaces
                                  ('http://www.w3.org/2003/05/soap-envelope' AS "env",
                                   'http://sap.com/xi/CRM/Global2' AS "nm",
                                   'urn:sap.com:proxy:DCT:/1SAI/TAS57DF0B317943DEAE3C49:702' AS "prx"
                                   '/env:Envelope/env:Body/nm:CustomerCRMByIDResponse/BusinessPartner'
                                   PASSING xml_response
                                   columns
                                   NOTES VARCHAR2(4000) PATH 'TextCollection/Text/TextContent/Text'
                             ) XMLRESPONSE;
    /* Output */
    NOTES -- DUMP_TEXT
    ä     Typ=1 Len=4 CharacterSet=AL32UTF8: 195,131,194,164But decimal notation for German character ä is different!
    SELECT DUMP('ä',1010) dump_text from dual;
    /*Output*/
    DUMP_TEXT
    Typ=96 Len=2 CharacterSet=AL32UTF8: 195,164Regards,
    Hari

  • Transaction Output when invoked Web Service

    Hi all,
    I have developed a transaction which has an output parameter of type list, derived from the classic ERP BAPI Flight Get List
    When I invoke the transaction as web service from a SOAP test tool I get a SOAP response like:
    <MyTestOutput>
    [[string:FRA], [string:TYO], [string:FCO],  [string:KIX]]
    </MyTestOutput>
    So the output xml element is just one, containing the whole list.
    I don't like this because the web service consumer must parse that element to get all the result items.
    What I would like is a more xml-like output structure, such as:
    <MyTestOutput>[string:FRA]</MyTestOutput>
    <MyTestOutput>[string:TYO]</MyTestOutput>
    <MyTestOutput>[string:FCO]</MyTestOutput>
    <MyTestOutput>[string:KIX]</MyTestOutput>
    Is there a simple way to achieve that?
    In the help/guides I have studied there's no hint about how to do so.
    Thanks, regards
    Vincenzo

    Hi Vincenzo,
    I reopened your thread. 
    Instead of making your output parameter type of List, create an output parameter of type xml.  If you look at most of the transactions available as downloads, you will see numerous examples of the types of structures the xml will accomodate.  And you will not have to convert the outputs back to xml for further processing.
    If you use a repeater to build your xml, you can accomplish the structure you desire.  Alternatively, you can build an MII Document and the format will be
    <Rowsets>
    <Rowset>
    <Row>
    <your Fieldname>
    data1
    </your Fieldname>
    </Row>
    <Row>
    <your Fieldname>
    data2
    </your Fieldname>
    </Row>
    <Row>
    <your Fieldname>
    data3
    </your Fieldname>
    </Row>
    <Row>
    <your Fieldname>
    data4
    </your Fieldname>
    </Row>
    </Rowset>
    </Rowsets>
    Regards,
    Mike
    Edited by: Michael Appleby on Sep 20, 2011 1:29 PM

  • Problem when invoke Web Service.

    Hi all.
    I have an interface that receive an IDoc and map it against a Web Services. In SXMB_MONI there is only one record and segment occurrence in XML is 0...1
    In Receiver system's log  figure that the web services was invoked too many times by XI.
    Any Idea about it?
    Thanks & Regards.
    RP

    Hi,
    May be it is because of the ReTry attempt from the integration engine to deliver the messages,,
    Check out the RWB>Message Monitoring>Message Display tool to do the analysis..
    How many messages are there in the SXMB_MONI ? I don't think so, it is because of occurence of the data.. check the message mapping...
    Rgds,
    moorthy

  • How to set clock skew property at client side when invoking web services

    Hello,
    now we're using weblogic 11g, we want to set the clock skew properties.
    in server side, we "Create a Web Service security" to set the "Clock Skew" property, change it value from 60000 to 120000, then we invoke the web service from stand-alone client on another machine, the clock skew between the server machine an client machine is 80000. but it still throw exception:
    javax.xml.ws.soap.SOAPFaultException: Message Created time past the current time even accounting for set clock skew+
    at weblogic.wsee.jaxws.framework.jaxrpc.TubeFactory$JAXRPCTube.processResponse(TubeFactory.java:241)+
    we think we still need set the clock skew at client side. in webloigc8.1 doc(http://download.oracle.com/docs/cd/E13222_01/wls/docs81/webserv/client.html), we find there's properties such as "weblogic.webservice.security.clock.precision" we can set in client side, but in weblogic 10.3 doc, we can't find these properties.
    now how to set the clock skew at stand-alone client in weblogic 11g?
    Thanks!
    Fred

    Hello,
    now we're using weblogic 11g, we want to set the clock skew properties.
    in server side, we "Create a Web Service security" to set the "Clock Skew" property, change it value from 60000 to 120000, then we invoke the web service from stand-alone client on another machine, the clock skew between the server machine an client machine is 80000. but it still throw exception:
    javax.xml.ws.soap.SOAPFaultException: Message Created time past the current time even accounting for set clock skew+
    at weblogic.wsee.jaxws.framework.jaxrpc.TubeFactory$JAXRPCTube.processResponse(TubeFactory.java:241)+
    we think we still need set the clock skew at client side. in webloigc8.1 doc(http://download.oracle.com/docs/cd/E13222_01/wls/docs81/webserv/client.html), we find there's properties such as "weblogic.webservice.security.clock.precision" we can set in client side, but in weblogic 10.3 doc, we can't find these properties.
    now how to set the clock skew at stand-alone client in weblogic 11g?
    Thanks!
    Fred

Maybe you are looking for

  • [Solved] X11 won't start after fresh install

    Hihi! I've been using Debian for quite some time now but I want to switch to Arch. My notebook is fairly modern and this doesn't mix well with Debian and as such my dGPU is basically unusable. My preferred method of installing Debian is to start head

  • I cannot to the internet via mozilla firefox - why?

    I updated to the latest version of firefox and now I cannot connect to the internet. The circling motion icon goes backwards. My home page is Yahoo.

  • Xml tag

    Hello, I'm on Java and I put a xml in a dom. Now I need to check that all "mytag" as a ddiferent "id" value: <xml........................>   <mttag id="one"............./>   <mttag id="two"............./>   <mttag id="one"............./> //--error  

  • PASSWORD FOR UNLOCKING IPOD BACKUP??

    i"ve updated my ipod and now im trying to restore my files but itunes is asking me for a password but i never set up one. is my password my apple I.D password?

  • XML APPROVAL PROCESS

    Hello Experts, I wonder if it is possible to enable approval process for a folder and all the folders that in it. i mean when i enable approval and set the steps the same approval process should be enabled. if this isn't possible then this is ridicul