Calling https web service from pl/sql

hi,
i've to call a web service from my database, after some research, i've tryed to use utl_dbws package to get the job, i've managed to put to work some of the examples i saw, that allways use http. My webservice is invoked using https with some user credentials.
i'me getting the following message:
ORA-29532: Java call terminated by uncaught Java exception: HTTP transport error:
javax.xml.soap.SOAPException: java.security.PrivilegedActionException:
javax.xml.soap.SOAPException: Message send failed: Socket is closed
ORA-06512: at "SYS.UTL_DBWS", line 388
ORA-06512: at "SYS.UTL_DBWS", line 385
ORA-06512: at line 85
i've tryed with this 2 procedures:
declare
service_ sys.utl_dbws.SERVICE;
call_ sys.utl_dbws.CALL;
service_qname sys.utl_dbws.QNAME;
port_qname sys.utl_dbws.QNAME;
operation_qname sys.utl_dbws.QNAME;
string_type_qname sys.utl_dbws.QNAME;
retx ANYDATA;
retx_string VARCHAR2(100);
retx_len number;
params sys.utl_dbws.ANYDATA_LIST;
wsm varchar2(4000);
config varchar2(4000);
request sys.XMLTYPE;
response sys.XMLTYPE;
begin
Request := sys.XMLTYPE('<?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:Header>'||
' <UserCredentials xmlns="http://tempuri.org/">'||
' <UserID>username</UserID>'||
' <Password>password</Password>'||
' </UserCredentials>'||
' </soap:Header>'||
' <soap:Body>'||
' <GetInfo xmlns="http://tempuri.org/">'||
' <wsID>13</wsID>'||
' </GetInfo>'||
' </soap:Body>'||
' </soap:Envelope>');
service_qname := sys.utl_dbws.to_qname(null, 'GetInfo');
service_ := sys.utl_dbws.create_service(service_qname);
operation_qname := sys.utl_dbws.to_qname('http://tempuri.org/', 'GetInfo');
call_ := sys.utl_dbws.create_call(service_);
sys.utl_dbws.set_target_endpoint_address(call_, 'https://ws.livesolutions.pt:8800/wsLivesolutions.asmx');
sys.utl_dbws.set_property( call_
, 'OPERATION_STYLE'
, 'document'
sys.utl_dbws.set_property( call_
, 'SOAPACTION_URI'
,' https://ws.livesolutions.pt:8800/wsLivesolutions');
response:= sys.utl_dbws.invoke(call_, request);
END;
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(1000);
retx_double number;
retx_len number;
params utl_dbws.ANYDATA_LIST;
l_input_params utl_dbws.anydata_list;
l_result ANYDATA;
l_namespace VARCHAR2(1000);
request sys.XMLTYPE;
response sys.XMLTYPE;
begin
l_namespace := 'http://tempuri.org/';
service_qname := utl_dbws.to_qname(l_namespace, 'wsLivesolutions');
service_ := utl_dbws.create_service(service_qname);
port_qname := utl_dbws.to_qname(l_namespace, 'wsLivesolutionsSoap');
operation_qname := utl_dbws.to_qname(l_namespace, 'GetInfo');
call_ := utl_dbws.create_call(service_, port_qname, operation_qname);
utl_dbws.set_target_endpoint_address(call_, 'https://ws.livesolutions.pt:8800/wsLivesolutions.asmx');
utl_dbws.set_property(call_, 'SOAPACTION_USE', 'TRUE');
utl_dbws.set_property(call_, 'SOAPACTION_URI', 'http://tempuri.org/GetInfo');
utl_dbws.set_property(call_, 'OPERATION_STYLE', 'document');
UTL_DBWS.set_property(call_, 'USERNAME', 'username');
UTL_DBWS.set_property(call_, 'PASSWORD', 'password');
string_type_qname := utl_dbws.to_qname('http://www.w3.org/2001/XMLSchema', 'schema');
utl_dbws.add_parameter(call_, 'wsID', string_type_qname, 'ParameterMode.IN');
utl_dbws.set_return_type(call_, string_type_qname);
params(0) := ANYDATA.convertnumber(13);
retx := utl_dbws.invoke(call_, params);
utl_dbws.release_service(service_);
end;
can anyone help me in this?
thx

Are you expecting us to guess at the message you received when you got the 28868?
I guess: "the wallet is closed."
If I guessed correctly then open it.
ALTER SYSTEM SET ENCRYPTION WALLET OPEN IDENTIFIED BY "<your_wallet_password_here>";If I didn't guess correctly then you need to provide all of the information you neglected in your original post.
Start with the version number.

Similar Messages

  • New to Web Services - need to call a HTTPS web service from PL/SQL

    I am new to Web Services and need to call HTTPS web service from PL/SQL program. I am using 10g Database.
    I have been reading there are 2 options -
    1. UTL_HTTP - with this package its possible to call HTTPS web services
    2. UTL_DBWS
    Questions -
    1. Is it possible to call a HTTPS web service using UTL_DBWS ? I have not been able to find any information on it.
    2. Can someone point me to UTL_HTTP and UTL_DBWS examples calling a HTTPS web service ?
    3. The HTTPS web service that I need to call needs username/password to connect - how will I incorporate this in the pl/sql code ?
    Appreciate the help.
    Cheers,
    newWebServicesUser

    Hi,
    1. UTL_DBWS not work for https from what I understand
    2. Here is a sample example:
    [http://www.oracle-base.com/articles/9i/ConsumingWebServices9i.php#]
    Be careful, you must change http/1.0 IN 1.1 inside package SOAP_API.
    Here is an example for a prime number where the SOAP message is already construct:
    CREATE OR REPLACE procedure test_ws_2
    IS
    http_req utl_http.req;
    http_resp utl_http.resp;
    request_env varchar2(32767);
    response_env varchar2(32767);
    begin
    -- Set proxy details if no direct net connection.
    UTL_HTTP.set_proxy('http://<USER>:<PASS>@10.0.2.21:8070', NULL);
    UTL_HTTP.set_persistent_conn_support(TRUE);
    request_env:='<?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/1999/XMLSchema-instance" xmlns:xsd="http://www.w3.org/1999/XMLSchema">'||
    '<SOAP-ENV:Body><GetPrimeNumbers xmlns="http://microsoft.com/webservices/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">'||
    '<max xsi:type="xsd:int">10</max>'||
    '</GetPrimeNumbers></SOAP-ENV:Body></SOAP-ENV:Envelope>';
    dbms_output.put_line('Length of Request:' || length(request_env));
    dbms_output.put_line ('Request: ' || request_env);
    http_req := utl_http.begin_request('http://www50.brinkster.com/vbfacileinpt/np.asmx','POST', utl_http.HTTP_VERSION_1_1);
    utl_http.set_header(http_req, 'Content-Type', 'text/xml; charset=utf-8');
    utl_http.set_header(http_req, 'Content-Length', length(request_env));
    utl_http.set_header(http_req, 'SOAPAction', '"http://microsoft.com/webservices/GetPrimeNumbers"');
    utl_http.write_text(http_req, request_env);
    dbms_output.put_line('');
    http_resp := utl_http.get_response(http_req);
    dbms_output.put_line('Response Received');
    dbms_output.put_line('--------------------------');
    dbms_output.put_line ( 'Status code: ' || http_resp.status_code );
    dbms_output.put_line ( 'Reason phrase: ' || http_resp.reason_phrase );
    utl_http.read_text(http_resp, response_env);
    dbms_output.put_line('Response: ');
    dbms_output.put_line(response_env);
    utl_http.end_response(http_resp);
    end test_ws_2;
    Otherwice for testing url, i recommand you to use that function: Re: Error using UTL_HTTP over HTTPS
    it's a verry helpful function when you have an error.
    wrote:
    When testing using UTL_HTTP, you MUST ensure that you open a new session after importing the SSL certificates into your Wallet,
    as I've learned (the hard way) that existing sessions point to the wallet contents that were present when the session was opened.
    If you don't realise/know this, it can cause a lot of additional frustration during testing, when you keep getting the ORA-29024 exception AFTER
    you've imported the SSL certificates................. ;) 3. i think you can use that after the begin_request but not sure :
    UTL_HTTP.set_authentication(r => http_req,
    username => ,
    password => ,
    scheme => ,
    for_proxy => );
    Edited by: Malebodja on Oct 22, 2009 6:53 AM
    Edited by: Malebodja on Oct 22, 2009 6:55 AM

  • Calling a Web Service from PL/SQL Procedure

    How can you call a web service from a pl/sql package , also is it valid to call a web service from pl/sql according to Fusion Standards..

    Hi,
    On way we can call a web service is to pass the Web Service URL to UTL_HTTP package:
    Sample Web Service URL
    ===================
    lv_url :=
    'http://67.97.189.151:8888/plsqlsample/dbfunc?invoke=placeOrder'
    || '&'
    || 'param0=1'
    || '&'
    || 'param1=1'
    || '&'
    || 'param2=1';
    Sample Call using UTL_HTTP
    =====================
    SELECT UTL_HTTP.request (lv_url)
    INTO lv_result
    FROM DUAL;
    Thank you.
    Regards,
    Balu

  • Calling secured web service from Pl SQL

    Hi
    I am trying to call a secured web service from pl/sql using utl_http.
    Is there a sample pl/sql program that i can refer to call a secured web service.
    sample soap header that am trying to acheive.
    <soap:Header>
    <wsa:Action>http://myactaction</wsa:Action>
    <wsa:MessageID>uuid:asdfadrewrwqr</wsa:MessageID>
    <wsa:ReplyTo>
    <wsa:Address>http://schemas.xmlsoap.org/ws/2004/03/addressing/role/anonymous</wsa:Address>
    </wsa:ReplyTo>
    <wsa:To>http://myact</wsa:To>
    <wsse:Security soap:mustUnderstand="1">
    <wsse:UsernameToken wsu:Id="SecurityToken-321321">
    <wsse:Username>mordfsafsdae</wsse:Username>
    <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">werwqrewrwe</wsse:Password>
    </wsse:UsernameToken>
    </wsse:Security>
    </soap:Header>
    Thanks a ton in advance

    Hi,
    On way we can call a web service is to pass the Web Service URL to UTL_HTTP package:
    Sample Web Service URL
    ===================
    lv_url :=
    'http://67.97.189.151:8888/plsqlsample/dbfunc?invoke=placeOrder'
    || '&'
    || 'param0=1'
    || '&'
    || 'param1=1'
    || '&'
    || 'param2=1';
    Sample Call using UTL_HTTP
    =====================
    SELECT UTL_HTTP.request (lv_url)
    INTO lv_result
    FROM DUAL;
    Thank you.
    Regards,
    Balu

  • Error while calling .svc web service from pl/sql using utl_dbws

    Hello Folks,
    I am calling a .svc web service from pl/sql using utl_dbws and encountering the following error
    javax.xml.rpc.soap.SOAPFaultException: The message with Action '' cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher. This may be because of either a contract mismatch (mismatched Actions between sender and receiver) or a binding/security mismatch between the sender and the receiver. Check that sender and receiver have the same contract and the same binding (including security requirements, e.g. Message, Transport, None).
    Can you help me find what am I doing wrong?
    Thanks
    Rk

    Hi,
    Here are the details
    1. What version?
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
    PL/SQL Release 10.2.0.4.0 - Production
    CORE 10.2.0.4.0 Production
    TNS for 64-bit Windows: Version 10.2.0.4.0 - Production
    NLSRTL Version 10.2.0.4.0 - Production
    2. What error message ... we need the full and complete error stack not your interpretation of it.
    ORA-29532: Java call terminated by uncaught Java exception: javax.xml.rpc.soap.SOAPFaultException: The message with Action '' cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher. This may be because of either a contract mismatch (mismatched Actions between sender and receiver) or a binding/security mismatch between the sender and the receiver. Check that sender and receiver have the same contract and the same binding (including security requirements, e.g. Messag
    3. "I am calling means what?" We need the full and complete statement showing the values of all parameters.
    The input to the web-service is a xmltype containing address information and the web-service returns a string
    CREATE OR REPLACE FUNCTION get_id
    RETURN VARCHAR2
    AS
    l_service UTL_DBWS.service;
    l_call UTL_DBWS.CALL;
    l_wsdl_url VARCHAR2 (32767);
    l_namespace VARCHAR2 (32767);
    l_service_qname UTL_DBWS.qname;
    l_port_qname UTL_DBWS.qname;
    l_operation_qname UTL_DBWS.qname;
    l_xmltype_in SYS.XMLTYPE;
    l_xmltype_out SYS.XMLTYPE;
    l_return VARCHAR2 (32767);
    BEGIN
    l_wsdl_url := 'http://test.com/test.svc?wsdl';
    l_namespace := 'http://test.org/';
    l_service_qname := UTL_DBWS.to_qname (l_namespace, 'SName');
    l_port_qname := UTL_DBWS.to_qname (l_namespace, 'BasicHttpBinding_ISName');
    l_operation_qname := UTL_DBWS.to_qname (l_namespace, 'Iden');
    l_service :=
    UTL_DBWS.create_service
    (wsdl_document_location => urifactory.geturi
    (l_wsdl_url),
    service_name => l_service_qname
    l_call :=
    UTL_DBWS.create_call (service_handle => l_service,
    port_name => l_port_qname,
    operation_name => l_operation_qname
    l_xmltype_in :=
    SYS.XMLTYPE
    ('<IdenRequest xmlns:i="http://www.w3.org/XMLSchema-instance" xmlns="http://test.org/SNameIden.WCFService">
    <address />
    <zip>12345</zip>
    <state>AA</state>
    <street>W Test </street>
    </address>
    </IdenRequest>'
    l_xmltype_out :=
    UTL_DBWS.invoke (call_handle => l_call,
    request => l_xmltype_in);
    UTL_DBWS.release_call (call_handle => l_call);
    UTL_DBWS.release_service (service_handle => l_service);
    l_return := l_xmltype_out.EXTRACT ('//Iden/text()').getstringval();
    RETURN l_return;
    END;
    /

  • Help calling a web service from pl/sql

    Hi, i have a web service that is called from a php, i needed to do this but from pl sql:
    this is the call of web service from php:
    <?PHP
    //Variables de prueba - Se tienen que tomar los valores de la base de datos, de la compra y el usuario
    $p_id_emec=urlencode("33355555"); //Identificador del sitio dentro de Pago Fácil
    $p_id_operacion=urlencode("151"); //Identificador unívoco de la compra en el sitio
    $p_id_mone_ecom=urlencode("01"); //Identificador de moneda - '01'=pesos - '02=dolares
    //Inicializa Variables de URL
    $serviceName="Pago XX";
    $protocol="http://";
    // DESARROLLO
    $ipUrl="desa.e-pagoxx.com";
    $port=80;
    //Llamada
    $call="/2130/index.php";
    //Abro la conexion al port
    $URLsola = $protocol.$ipUrl;
    //Concatenacion del string
    $txtURL = $protocol.$ipUrl.$call;
    $txtURL .="?p_id_emec=".$p_id_emec;
    $txtURL .="&p_id_operacion=".$p_id_operacion;
    $txtURL .="&p_id_mone_ecom=".$p_id_mone_ecom;
    $txtURL = $txtURL;
    //* Se comunica con el servidor, pasa los datos y recibe el HTML con el comprobante *//
    $fp = fsockopen($ipUrl, $port, &$errno, &$errstr, 30);
    if(!$fp)
    echo "No me puedo comunicar con $serviceName";
    exit;
    else
    $file=@fopen($URLsola,"r");
    $pageData=file($txtURL);
    for($i=0;$i<count($pageData);$i++)
              $sText.=$pageData[$i];
    @fclose($file);
    @fclose($fp);
    echo($sText);
    ?>
    I need to call this webservice from pl sql
    any ideas?
    thanks!!

    Madhu BR wrote:
    You might want to try the webservice call using utl_http specified here : http://orclpps.blogspot.com/2007/12/invoking-webservices-from-oracle-9i-or.html
    Or even to expand on that to deal with responses larger than 32K...
    -- skeleton code
      PROCEDURE p_soap_request(p_username IN VARCHAR2, p_password IN VARCHAR2, p_proxy IN VARCHAR2) IS
        soap_request  VARCHAR2(30000);
        soap_respond  CLOB;
        http_req      utl_http.req;
        http_resp     utl_http.resp;
        resp          XMLType;
        soap_err      exception;
        v_code        VARCHAR2(200);
        v_msg         VARCHAR2(1800);
        v_len number;
        v_txt Varchar2(32767);
      BEGIN
        IF p_proxy IS NOT NULL THEN
          UTL_HTTP.SET_PROXY(p_proxy);
        END IF;
        -- Define the SOAP request according the the definition of the web service being called
        soap_request:= '<?xml version = "1.0" encoding = "UTF-8"?>'||
                       '<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">'||
                       '  <SOAP-ENV:Body>'||
                       '    <m:DownloadRequest xmlns:m="http://www.website.net/messages/GetDetails">'||
                       '      <m:UserName>'||p_username||'</m:UserName>'||
                       '      <m:Password>'||p_password||'</m:Password>'||
                       '    </m:DownloadRequest>'||
                       '  </SOAP-ENV:Body>'||
                       '</SOAP-ENV:Envelope>';
        http_req:= utl_http.begin_request
                  ( 'http://www.website.net/webservices/GetDetailsService.asmx'
                  , 'POST'
                  , 'HTTP/1.1'
        utl_http.set_header(http_req, 'Content-Type', 'text/xml');
        utl_http.set_header(http_req, 'Content-Length', length(soap_request));
        utl_http.set_header(http_req, 'Download', ''); -- header requirements of particular web service
        utl_http.write_text(http_req, soap_request);
        http_resp:= utl_http.get_response(http_req);
        utl_http.get_header_by_name(http_resp, 'Content-Length', v_len, 1); -- Obtain the length of the response
        FOR i in 1..CEIL(v_len/32767) -- obtain response in 32K blocks just in case it is greater than 32K
        LOOP
            utl_http.read_text(http_resp, v_txt, case when i < CEIL(v_len/32767) then 32767 else mod(v_len,32767) end);
            soap_respond := soap_respond || v_txt; -- build up CLOB
        END LOOP;
        utl_http.end_response(http_resp);
        resp:= XMLType.createXML(soap_respond); -- Convert CLOB to XMLTYPE
      END;

  • How to call "https" web service from Oracle without certification.

    The reuirement is to call a secured web service (*https web service*) from Oracle9i without involving any additional cost.
    Initialy I tried with UTL_HTTP package but in vain as it is needed some certification. As per the requirement no additional cost should be involved with the implementation.
    So is there any way to achieve the above mentioned problem?
    Please let me know the responses with the sample code/steps.

    Please try not to double post. You have the ability to edit your original thread.
    Oh, BTW, try searching the forum. A quick search turned up this: HTTPS request signed by client certificate from PL/SQL procedure
    Check that out and maybe that will solve your problems.
    Thanks!

  • Errors calling oracle web service from pl/sql

    Oracle application server version 10.1.2.2.0
    Jdeveloper version 10.1.2.1.0
    I have published a function of an oracle database package as a web service using jdeveloper by creating a connection to my database and right clicking on the package and selecting publish as a web service. I accepted all the defaults and deployed the web service to my application server also using jdeveloper. I have been able to invoke the web service from the url which was generated.
    I now want to invoke this web service from another pl/sql procedure in the same database as the function I've published as a web service using the utl_dbws facility but get the following error
    ORA-29532: Java call terminated by uncaught Java exception: javax.xml.rpc.soap.SOAPFaultException: No Deserializer found to deserialize a 'http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/:p_group_id' using encoding style 'null'. [java.lang.IllegalArgumentException]
    I have amended the wsdl to look like this
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <!--Generated by the Oracle JDeveloper 10g Web Services WSDL Generator-->
    <!--Date Created: Tue Sep 29 12:32:20 BST 2009-->
    <wsdl:definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:s="http://www.w3.org/2001/XMLSchema"
    xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:tns="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/"
    xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
    xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
    targetNamespace="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
    <wsdl:types>
    <s:schema elementFormDefault="qualified"
    targetNamespace="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/">
    <s:element name="totalliveusers">
    <s:complexType>
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="1" name="p_group_id" type="s:string"/>
    </s:sequence>
    </s:complexType>
    </s:element>
    <s:element name="totalliveusersResponse">
    <s:complexType>
    <s:sequence>
    <s:element minOccurs="0" maxOccurs="1" name="totalliveusersResult" type="s:int"/>
    <s:element minOccurs="0" maxOccurs="1" name="p_group_desc" type="s:string"/>
    </s:sequence>
    </s:complexType>
    </s:element>
    </s:schema>
    </wsdl:types>
    <wsdl:message name="totalliveusersSoapIn">
    <wsdl:part name="parameters" element="tns:totalliveusers"/>
    </wsdl:message>
    <wsdl:message name="totalliveusersSoapOut">
    <wsdl:part name="parameters" element="tns:totalliveusersResponse"/>
    </wsdl:message>
    <wsdl:portType name="totalliveusersSoap">
    <wsdl:operation name="totalliveusers">
    <wsdl:input message="tns:totalliveusersSoapIn"/>
    <wsdl:output message="tns:totalliveusersSoapOut"/>
    </wsdl:operation>
    </wsdl:portType>
    <wsdl:binding name="totalliveusersSoap" type="tns:totalliveusersSoap">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <wsdl:operation name="totalliveusers">
    <soap:operation
    soapAction="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS/totalliveusers"
    style="document"/>
    <wsdl:input>
    <soap:body use="literal"/>
    </wsdl:input>
    <wsdl:output>
    <soap:body use="literal"/>
    </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name="totalliveusers">
    <wsdl:port name="totalliveusersSoap" binding="tns:totalliveusersSoap">
    <soap:address location="http://fujibox09/FinalTestWS-Project-context-root/FinalTestWS"/>
    </wsdl:port>
    </wsdl:service>
    </wsdl:definitions>
    The function has an in varchar2 parameter and an out varchar2 parameter and returns a number
    Can anyone help?

    Hi,
    On way we can call a web service is to pass the Web Service URL to UTL_HTTP package:
    Sample Web Service URL
    ===================
    lv_url :=
    'http://67.97.189.151:8888/plsqlsample/dbfunc?invoke=placeOrder'
    || '&'
    || 'param0=1'
    || '&'
    || 'param1=1'
    || '&'
    || 'param2=1';
    Sample Call using UTL_HTTP
    =====================
    SELECT UTL_HTTP.request (lv_url)
    INTO lv_result
    FROM DUAL;
    Thank you.
    Regards,
    Balu

  • Calling SharePoint Web Services from PL/SQL

    We are trying to call SharePoint Web Services with UTL_DBWS or UTL_HTTP. We are able to call some test web services, but when it comes to using SharePoint services, we keep getting 401 errors..even when we use set_authorization.
    Has anyone been able to use UTL_DBWS or UTL_HTTP to call SharePoint web services? If so, can you point us in the right direction?
    Thanks

    AB,
    I didn't realize you cannot attach documents to your post. You will have to provide me with an email address that I can send the documents to. They are a little rough (ie not commented etc) but they do illustrate the point. The basic idea is to build up the payload of the soap envelope using pl/sql. Meaning as I loop through the cursor I use each record in the cursor to build an xml string. This string of xml becomes the payload of the soap message. This could also be done using xml functionality provided by the db meaning xmlelement, xmlforest etc. The issue I ran into was the size of the message. That is why I elected to build the xml message by string concatenation as I moved through the cursor.
    Ryan

  • Connection close exception while calling HTTPS web service from BlackBerry 8100 using KSOAP

    Hi
    I am trying to call HTTPS we services using J2ME Polish application and using KSOAP.
    My Application works fine on other device Blackberry Bold, curve. But on BlackBerry 8100 pearl  it gives me 
    net.rim.device.api.io.connectionclosed exception.
    Device Description : BlackBerry Pearl 8100
    OS                       : 4.2
     Please help me out in this issue.
    Regards
    Amit Deshpande

    Hi
    I am trying to call HTTPS we services using J2ME Polish application and using KSOAP.
    My Application works fine on other device Blackberry Bold, curve. But on BlackBerry 8100 pearl  it gives me 
    net.rim.device.api.io.connectionclosed exception.
    Device Description : BlackBerry Pearl 8100
    OS                       : 4.2
     Please help me out in this issue.
    Regards
    Amit Deshpande

  • Oracle 9i: Help with loadjava jar files to call out web service from pl/sql

    I'm trying to build a web service client using dbws_callout_utility.zip (version used for prio 10g database). I followed the articles in oracle site to loadjava jar files (soap.jar, dms.jar, ejb.jar, jssl-1_1.jar, mail.jar, servlet.jar) into Oracle DB 9i before invoke jpub to gen stub class and wrappers in oracle 9i but i have many errors such as ora-29534 and ora-29521. As consequence i could not invoke jpublisher to generate code.
    Pls. help my with detail guide to overcome these errors, thanks in advance! My DB is Oracle 9.2.0.5

    Dear,
    I have read your article, it is useful for me. But I cannot Apply to my case. Please kindly help me. Thank you.
    When running, the error occurs:
    1:39:31 Execution failed: ORA-20000: soapenv:Server.userException - org.xml.sax.SAXParseException: Attribute name &quot;password&quot; associated with an element type &quot;user&quot; must be followed by the &apos; = &apos; character.
    My webservice Url: http://abc.com.vn:81/axis/ABC_WS_TEST.jws?wsdl
    I make PL/SQL (similiar as your example)
    FUNCTION INVOKESENDMT
    RETURN VARCHAR2
    AS
    l_request soap_api.t_request;
    l_response soap_api.t_response;
    l_return VARCHAR2(32767);
    l_url VARCHAR2(32767);
    l_namespace VARCHAR2(32767);
    l_method VARCHAR2(32767);
    l_soap_action VARCHAR2(32767);
    l_result_name VARCHAR2(32767);
    p_zipcode VARCHAR2(160);
    BEGIN
    --p_zipcode:='''TEST'' ; ''TEST'';''84912187098'';''84912187098'';''0'';''8118'';''1'';''000001'';''ThuNghiem'';''''';
    p_zipcode:='TEST';
    -- Set proxy details if no direct net connection.
    --UTL_HTTP.set_proxy('myproxy:4480', NULL);
    --UTL_HTTP.set_persistent_conn_support(TRUE);
    -- Set proxy authentication if necessary.
    --soap_api.set_proxy_authentication(p_username => 'TEST',
    -- p_password => 'TEST');
    l_url := 'http://abc.com.vn:81/axis/ABC_WS_TEST.jws';
    l_namespace := 'xmlns="' || l_url || '"';
    l_method := 'sendMT';
    l_soap_action := l_url || '#sendMT';
    l_result_name := 'sendMTResponse';
    l_request := soap_api.new_request(p_method => l_method,
    p_namespace => l_namespace);
    soap_api.add_parameter(p_request => l_request,
    p_name => 'user password sender receiver chargedflag servicenumber messagetype messageid textcontent binarycontent',
    p_type => 'xsd:string',
    p_value => p_zipcode);
    l_response := soap_api.invoke(p_request => l_request,
    p_url => l_url,
    p_action => l_soap_action);
    l_return := soap_api.get_return_value(p_response => l_response,
    p_name => l_result_name,
    p_namespace => l_namespace);
    RETURN l_return;
    END;

  • How to call a web service from PL/SQL?

    The link to this article seems to be gone, and I can't find much information out there? Does anyone have a link that works? Or perhaps archived the old article at the bottom of this page:
    http://www.oracle-base.com/articles/9i/ConsumingWebServices9i.php

    Dear,
    I have read your article, it is useful for me. But I cannot Apply to my case. Please kindly help me. Thank you.
    When running, the error occurs:
    1:39:31 Execution failed: ORA-20000: soapenv:Server.userException - org.xml.sax.SAXParseException: Attribute name &quot;password&quot; associated with an element type &quot;user&quot; must be followed by the &apos; = &apos; character.
    My webservice Url: http://abc.com.vn:81/axis/ABC_WS_TEST.jws?wsdl
    I make PL/SQL (similiar as your example)
    FUNCTION INVOKESENDMT
    RETURN VARCHAR2
    AS
    l_request soap_api.t_request;
    l_response soap_api.t_response;
    l_return VARCHAR2(32767);
    l_url VARCHAR2(32767);
    l_namespace VARCHAR2(32767);
    l_method VARCHAR2(32767);
    l_soap_action VARCHAR2(32767);
    l_result_name VARCHAR2(32767);
    p_zipcode VARCHAR2(160);
    BEGIN
    --p_zipcode:='''TEST'' ; ''TEST'';''84912187098'';''84912187098'';''0'';''8118'';''1'';''000001'';''ThuNghiem'';''''';
    p_zipcode:='TEST';
    -- Set proxy details if no direct net connection.
    --UTL_HTTP.set_proxy('myproxy:4480', NULL);
    --UTL_HTTP.set_persistent_conn_support(TRUE);
    -- Set proxy authentication if necessary.
    --soap_api.set_proxy_authentication(p_username => 'TEST',
    -- p_password => 'TEST');
    l_url := 'http://abc.com.vn:81/axis/ABC_WS_TEST.jws';
    l_namespace := 'xmlns="' || l_url || '"';
    l_method := 'sendMT';
    l_soap_action := l_url || '#sendMT';
    l_result_name := 'sendMTResponse';
    l_request := soap_api.new_request(p_method => l_method,
    p_namespace => l_namespace);
    soap_api.add_parameter(p_request => l_request,
    p_name => 'user password sender receiver chargedflag servicenumber messagetype messageid textcontent binarycontent',
    p_type => 'xsd:string',
    p_value => p_zipcode);
    l_response := soap_api.invoke(p_request => l_request,
    p_url => l_url,
    p_action => l_soap_action);
    l_return := soap_api.get_return_value(p_response => l_response,
    p_name => l_result_name,
    p_namespace => l_namespace);
    RETURN l_return;
    END;

  • Urgent: Calling web service from PL/SQl fails with XML parsing

    Hi,
    I am trying to call a web service from PL/SQL (using SOAP protocol and UTL_HTTP built in Package).I am using Oracle 9i .I am calling from pl/sql block invoking web service method created in java.
    I am getting the below response object as a SOAP protocol, but i couldn't able to parse the SOAP.
    Could you please provide the values of FirstName, LastName and ErrorDescription
    declare
    request_env varchar2(32767);
    v_xml XMLTYPE;
    l_user_first_name varchar2(100);
    l_user_last_name varchar2(100);
    l_error_value varchar2(100);
    begin
    response_env:='<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
    <soapenv:Body>
    <UserInfoObjResponse xmlns:axis2ns1="http://www.test.com/services">
    <axis2ns1:FirstName >First Name Output</axis2ns1:FirstName>
    <axis2ns1:LastName>Last Name Output</axis2ns1:LastName>
    <axis2ns1:ErrorDescription />
    </UserInfoObjResponse>
    </soapenv:Body>
    </soapenv:Envelope>';
    dbms_output.put_line('Length of Request:' || length(response_env));
    dbms_output.put_line ('Request: ' || response_env);
    v_xml := XMLTYPE(response_env);
    -- SELECT EXTRACTVALUE(v_xml, '//UserInfoObjResponse/FirstName') INTO l_user_fast_name varchar2(100); FROM DUAL;
    dbms_output.put_line ('l_user_first_name: ' || l_user_first_name);
    dbms_output.put_line ('l_user_last_name : ' || l_user_last_name);
    dbms_output.put_line ('l_error_value: ' || l_error_value);
    end;

    In Oracle 9i:
    SQL> declare
      2    response_env varchar2(32767);
      3    v_xml XMLTYPE;
      4    l_user_first_name varchar2(100);
      5    l_user_last_name varchar2(100);
      6    l_error_value varchar2(100);
      7  begin
      8    response_env:='<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
      9                     <soapenv:Body>
    10                       <UserInfoObjResponse xmlns:axis2ns1="http://www.test.com/services">
    11                         <axis2ns1:FirstName >First Name Output</axis2ns1:FirstName>
    12                         <axis2ns1:LastName>Last Name Output</axis2ns1:LastName>
    13                         <axis2ns1:ErrorDescription />
    14                       </UserInfoObjResponse>
    15                     </soapenv:Body>
    16                   </soapenv:Envelope>';
    17
    18    dbms_output.put_line('Length of Request:' || length(response_env));
    19  --  dbms_output.put_line ('Request: ' || response_env);
    20
    21    v_xml := XMLTYPE(response_env);
    22
    23    select EXTRACTVALUE(v_xml,'/*:Envelope/*:Body/*:UserInfoObjResponse/*:FirstName/text()') first_name,
    24           EXTRACTVALUE(v_xml,'/*:Envelope/*:Body/*:UserInfoObjResponse/*:LastName/text()') last_name,
    25           EXTRACTVALUE(v_xml,'/*:Envelope/*:Body/*:UserInfoObjResponse/*:ErrorDescription/text()') error_description
    26      into l_user_first_name, l_user_last_name, l_error_value
    27      from dual;
    28
    29    dbms_output.put_line ('l_user_first_name: ' || l_user_first_name);
    30    dbms_output.put_line ('l_user_last_name : ' || l_user_last_name);
    31    dbms_output.put_line ('l_error_value: ' || l_error_value);
    32  end;
    33  /
    Length of Request:530
    l_user_first_name: First Name Output
    l_user_last_name : Last Name Output
    l_error_value:
    PL/SQL procedure successfully completed.In Oracle 10g:
    SQL> declare
      2    response_env varchar2(32767);
      3    v_xml XMLTYPE;
      4    l_user_first_name varchar2(100);
      5    l_user_last_name varchar2(100);
      6    l_error_value varchar2(100);
      7  begin
      8    response_env:='<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
      9                     <soapenv:Body>
    10                       <UserInfoObjResponse xmlns:axis2ns1="http://www.test.com/services">
    11                         <axis2ns1:FirstName >First Name Output</axis2ns1:FirstName>
    12                         <axis2ns1:LastName>Last Name Output</axis2ns1:LastName>
    13                         <axis2ns1:ErrorDescription />
    14                       </UserInfoObjResponse>
    15                     </soapenv:Body>
    16                   </soapenv:Envelope>';
    17
    18    dbms_output.put_line('Length of Request:' || length(response_env));
    19  --  dbms_output.put_line ('Request: ' || response_env);
    20
    21    v_xml := XMLTYPE(response_env);
    22
    23    select r.*
    24      into l_user_first_name, l_user_last_name, l_error_value
    25    from XMLTABLE('/' PASSING v_xml
    26                  COLUMNS
    27                  first_name varchar2(30) PATH '/*:Envelope/*:Body/*:UserInfoObjResponse/*:FirstName/text()',
    28                  last_name varchar2(30) PATH '/*:Envelope/*:Body/*:UserInfoObjResponse/*:LastName/text()',
    29                  error_description varchar2(30) PATH '/*:Envelope/*:Body/*:UserInfoObjResponse/*:ErrorDescrition/text()'
    30                  ) r;
    31
    32    dbms_output.put_line ('l_user_first_name: ' || l_user_first_name);
    33    dbms_output.put_line ('l_user_last_name : ' || l_user_last_name);
    34    dbms_output.put_line ('l_error_value: ' || l_error_value);
    35  end;
    36  /
    Length of Request:530
    l_user_first_name: First Name Output
    l_user_last_name : Last Name Output
    l_error_value:
    PL/SQL procedure successfully completed.Max
    http://oracleitalia.wordpress.com
    Edited by: Massimo Ruocchio on Feb 14, 2010 11:55 PM
    Added the first one.

  • Calling web services from PL/SQL

    Hi,
    We have a requirement where we need to call a web services from PL/SQL.
    I believe we have a PL/SQL API that allows you to consume external web services.
    I was looking for other possible options too to consume web Service from PL/SQL.
    Can any one suggest the other possible options , and which option is best to consume web service.
    Thanks
    AB

    AB,
    I didn't realize you cannot attach documents to your post. You will have to provide me with an email address that I can send the documents to. They are a little rough (ie not commented etc) but they do illustrate the point. The basic idea is to build up the payload of the soap envelope using pl/sql. Meaning as I loop through the cursor I use each record in the cursor to build an xml string. This string of xml becomes the payload of the soap message. This could also be done using xml functionality provided by the db meaning xmlelement, xmlforest etc. The issue I ran into was the size of the message. That is why I elected to build the xml message by string concatenation as I moved through the cursor.
    Ryan

  • SR: Calling Web Services from PL/SQL gives http 500 errors

    Hi, people from Oracle Support sent me to this forum.
    I'm trying to call the Calendar Web Services from PL/SQL using the utl_http package, but I'm getting http-500 errors.
    I'm using the example from http://www.oracle.com/technology/tech/webservices/htdocs/samples/dbwebservice/DBWebServices_PLSQL.html
    Here's the code
    procedure showHtml
    as
    req soap_rpc.request;
    resp soap_rpc.response;
    BEGIN
    req := soap_rpc.new_request('cwsl:NoOp',
    'xmlns:cwsl="http://www.oracle.com/WebServices/Calendaring/1.0/"');
    resp := soap_rpc.invoke(req,
    'http://nllx004.nl.oracle.com/ocws-bin/ocas.fcgi',
    dbms_output.put_line(resp.doc.getStringVal());
    END;
    Can anyone help?

    I am new to web services and am having trouble getting the utl_http.set_header call to work using pl/sql. listed below is the code.
    CREATE OR REPLACE PACKAGE BODY adm_iModules_test
    AS
    NAME: Admissions iModules testing program
    PURPOSE:
    Ver Date Author Description
    REVISIONS:
    1.0 01/04/08 Julie Michael 1. Created this package body.
    PROCEDURE adm_iModules_test_output
    IS
    --cursor to select data to populate output file
    CURSOR c_iModules_main
    IS
    SELECT DISTINCT spriden_id sprid_id,
                                  spriden_pidm sprid_pidm,
                                  spriden_last_name sprid_last,
    spriden_first_name sprid_first,
                                  spriden_MI sprid_mid,
    spriden_create_date sprid_create_date,
    spriden_activity_date sprid_activity_date,
                                  spbpers_pidm pers_pidm,
    spbpers_name_prefix prefix,
    spbpers_name_suffix suffix,
                                  spbpers_dead_ind deceased_ind,
                                  spbpers_dead_date deceased_date,
                                  spbpers_birth_date, --added birth date
                                  spbpers_sex, --added gender
                                  goremal_pidm emal_pidm,
    goremal_email_address email_address,
                                  saradap_pidm app_pidm,
                                  zzrimod_member_id imod_id,
                                  gobtpac_external_user user_id
    FROM spriden,
    spbpers,
    goremal,
                                  saradap,
                                  zzrimod,
                                  gobtpac
    WHERE spriden_pidm = spbpers_pidm
    AND spriden_change_ind IS NULL
    AND spriden_pidm = goremal_pidm
                             AND goremal_emal_code = 'PERS'
                             AND goremal_preferred_ind = 'Y'
                             AND spriden_pidm = saradap_pidm
                             AND spriden_pidm = 120116
                             AND spriden_pidm = gobtpac_pidm
                             AND spriden_pidm = zzrimod_pidm(+)
                             AND goremal_preferred_ind = 'Y'
                             AND saradap_term_code_entry in ('200810','200820','200830');
         v_record      VARCHAR2 (32000) := null;
         v_record_counter               NUMBER                    := 0;
    f_iModules_output_test UTL_FILE.file_type;
    f_iModules_filename_test VARCHAR2 (50) := 'Adm_iModules_Test.TXT';
    f_iModules_dir_test VARCHAR2 (100) := 'TMP';
         v_separator                    VARCHAR2 (50)          := ',';
         v_id                              VARCHAR2 (90)          := '';
         v_fname                         VARCHAR2 (40)          := '';
         v_lname                         VARCHAR2 (40)          := '';
         v_user                         VARCHAR2 (90)          := '';
         v_login                         VARCHAR2 (100)          := '';
         v_password                    VARCHAR2 (100)          := '';
    -- v_link                         VARCHAR2 (32767)     := 'http://imodules.com/Web%20Services/';
         --the below item 'http://admin.imodules.com - was https://admin.imodules.com
         v_link                         VARCHAR2 (32767)      := 'http://admin.imodules.com/ws_10/MemberQuery.asmx?WSDL';
         v_non_existing_ids          VARCHAR2 (100)          := '"false"';
         v_style                         VARCHAR2 (5)           := '"1"';
         v_imod_member_id               VARCHAR2 (100)      := '';
         v_spriden_first_name           VARCHAR2 (60)          := '';
         req                Utl_Http.req;           --for posting
         resp                Utl_Http.resp;          --for posting
         v_msg                VARCHAR2(80);          --for posting
         H_Name                VARCHAR2(255);          --for posting
         H_Value                VARCHAR2(1023);     --for posting
         v_data_xml                    VARCHAR2(10000);
         BEGIN
                   DBMS_OUTPUT.ENABLE(1000000);
              f_iModules_output_test := UTL_FILE.fopen (f_iModules_dir_test, f_iModules_filename_test, 'w',32767);
                   v_record := '';
                   --needed for posting
    --                Utl_http.set_proxy(proxy => 'xxx.yyy.com',
    --      no_proxy_domains => 'xxx.com');
                   req := Utl_Http.begin_request(url => v_link,
    method => 'POST');
    --                          FOR v_iModules2 IN c_iModules_main
    --                          LOOP     
    --                                    v_record_counter := v_record_counter + 1;
    --                          END LOOP;
                             -- v_record := 'DUQ'||','||v_record_counter||','||to_char(SYSDATE,'mm/dd/yyyy');
                             UTL_FILE.put_line (f_iModules_output_test, v_record, false);     
                                       v_record := null;
                                  FOR v_iModules IN c_iModules_main
                                  LOOP
                                            v_id := v_imodules.sprid_id;
                                            v_fname := v_imodules.sprid_first||'test';
                                            v_lname := v_imodules.sprid_last;     
                                            v_user := '"'||v_imodules.email_address||'"';
                                            v_imodules.imod_id := '29';
                                            v_imod_member_id := '"'||v_imodules.imod_id||'"';
                                            v_spriden_first_name := '"SPRIDEN_FIRST_NAME"';
                                            v_login := '"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx"';
                                            v_password := '"xxxxxxxxxxxxxxxxxxxxxxxx"';
                                            v_record :='<?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>'||'<Update xmlns:m='||v_link||'>'||'<AUTHENTICATION login='||v_login||' '||
                                            'password='||v_password||' '||'addNonExistingIDs='||v_non_existing_ids||' '||'style='||
                                            v_style||'/>'||'<MemberInformation ZZRIMOD_MEMBER_ID='||v_imod_member_id||'>'||
                                            '<SPRIDEN_FIRST_NAME>'||v_fname||'</SPRIDEN_FIRST_NAME>'||'</MemberInformation>'||'</Update>'||
                                            '</soap:Body></soap:Envelope>';
    --                                         v_record := v_record := v_record||'<Update xmlns:m='||v_link||'>'||'<AUTHENTICATION login='||v_user||'>'||' '||
    --                                                   'password='||v_password||' '||'addNonExistingIDs='||v_non_existing_ids||' '||'style='||
    --                                                   v_style||'/>'||'<MemberInformation ZZRIMOD_MEMBER_ID='||v_imod_member_id||' '||
    --                                                   'column='||'"SPRIDEN_FIRST_NAME"'||' '||'newValue='||v_fname||'/>'||'</Update>';
                                            dbms_output.put_line('code: '||v_record);
                                            --v_record := v_record||v_separator||v_id||v_separator||v_name||v_separator||v_email;
                                       --Http posting calls
                                            Utl_Http.set_header(r => req,
                                            name => 'Content-Type',
                                            value => 'text/xml');
                                       Utl_Http.set_header(r => req,
                                            name => 'Content-Length',
                                            value => to_char(length(v_record)) );
                                            --JAM 03/25/08 - added to accomodate the missing soap action error                           
                                            Utl_Http.set_header(r => req,
                                            name => 'SOAPAction',
                                            value => 'http://admin.imodules.com/ws_10/MemberQuery.asmx?WSDL');
                                            Utl_Http.set_header(r => req,
                                            name => 'MessageType',
                                            value => 'CALL');
    --                                    Utl_Http.set_authentication(r => req,
    --                                         username => 'zzz',
    --                                                   password => 'ppppp',
    --                               scheme => 'Basic',
    --                               for_proxy => FALSE);
                                       Utl_Http.write_text(r => req,
                                            data => v_record);     
                                            resp := Utl_Http.get_response(r => req,
                             return_info_response => TRUE);
                                            DBMS_OUTPUT.put_line('Status Code: ' || resp.status_code);
                                            DBMS_OUTPUT.put_line('Reason Phrase: ' || resp.reason_phrase);
                                            dbms_output.put_line('testing');
                                            FOR i IN 1 .. Utl_Http.get_header_count(r => resp)
                                            LOOP
                                            Utl_Http.get_header(r => resp,
                   n => i,
                   name => H_Name,
                   value => H_Value);
                                            --DBMS_OUTPUT.put_line( ... );
                                            END LOOP;
                                            BEGIN
                                            LOOP
                                            Utl_Http.read_text(r => resp, DATA => v_msg);
                                            DBMS_OUTPUT.put_line(v_msg);
                                            END LOOP;
                                                 EXCEPTION
                                                 WHEN Utl_Http.end_of_body THEN
                                                 NULL;
                                                 END;          
                                                 Utl_Http.end_response(r => resp);      
    --                                              EXCEPTION
    --                                              WHEN Utl_Http.request_failed THEN
    --                                                   DBMS_OUTPUT.put_line('Request failed: '||Utl_Http.Get_Detailed_Sqlerrm);
    --                                                   WHEN Utl_Http.http_server_error THEN
    --                                                   DBMS_OUTPUT.put_line('Http_Server_Error: '||Utl_Http.Get_Detailed_Sqlerrm);
    --                                                   WHEN Utl_Http.http_client_error THEN
    --                                                   DBMS_OUTPUT.put_line('Client Error: '||Utl_Http.Get_Detailed_Sqlerrm);
    --                                                   WHEN others THEN     
    --                                                   DBMS_OUTPUT.put_line('Others2: '||Utl_Http.Get_Detailed_Sqlerrm);     
    --                                                   Utl_Http.end_response(r => resp);     
    --                                              END;
                                            --End of Htp posting calls
                                            --UTL_FILE.put_line (f_iModules_output_test, v_record, false);
                                            --htp.p('<post>'||v_record||'</post>');
                                            END LOOP;
                                                 EXCEPTION
                                                 WHEN Utl_Http.request_failed THEN
                                                      DBMS_OUTPUT.put_line('Request failed: '||Utl_Http.Get_Detailed_Sqlerrm);
                                                      WHEN Utl_Http.http_server_error THEN
                                                      DBMS_OUTPUT.put_line('Http_Server_Error: '||Utl_Http.Get_Detailed_Sqlerrm);
                                                      WHEN Utl_Http.http_client_error THEN
                                                      DBMS_OUTPUT.put_line('Client Error: '||Utl_Http.Get_Detailed_Sqlerrm);
                                                      WHEN others THEN     
                                                      DBMS_OUTPUT.put_line('Others2: '||Utl_Http.Get_Detailed_Sqlerrm);     
                                                      Utl_Http.end_response(r => resp);     
                                                 END;
                        -- close output file
                   --UTL_FILE.fclose (f_iModules_output_test);
                             --COMMIT;
                             /*EXCEPTION
                        WHEN OTHERS
                        THEN
                   ROLLBACK;
                   DBMS_OUTPUT.put_line ('Other Exception:' || SQLERRM);
                             -- DBMS_OUTPUT.put_line ('Other Exception:' || Utl_Http.Get_Detailed_Sqlerrm);
                             --COMMIT; */
                             -- END adm_iModules_test_output;
                             END adm_iModules_test;
    Message was edited by:
    user627523

Maybe you are looking for