analyze a soap envelope

I have a SOAP response envelope that I try to analyse using extractvalue.

The answer is stored in an xmltype field in a table.

Table
create table ws_results
(x xmltype);
SOAP response
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
     <s:Header>
          <ActivityId CorrelationId="12855f8e-d2be-40c7-81d8-fafa3cf9a779" xmlns="http://schemas.microsoft.com/2004/09/ServiceModel/Diagnostics">d24174d3-e095-460a-b9f8-2bae66efe813</ActivityId>
     </s:Header>
     <s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
          <FetchResponse xmlns="urn: WA.Ecy.ADS.FacilitySite.Services">
               <FacilitySiteId>99997167</FacilitySiteId>
          </FetchResponse>
     </s:Body>
</s:Envelope>
Here's the SQL code I try to use to obtain the Site ID of the installation
select extractvalue(x,'/FetchResponse/FacilitySiteId') from ws_results;

select extractvalue(x,'/FetchResponse/FacilitySiteId','xmlns="http://microsoft.com/wsdl/types/"')
from ws_results
It returns a null value.

Seems like it should be simple enough and I'm sure I'm missing something small. Any help would be appreciated.

Thank you, Tony

If it looks like you have levels and different node names. In such cases, you can do a v_xml.existNode ('/ / FetchResponse ',' xmlns = "http://yourNameSpaceLocation" ') > 0 or v_xml.existNode ('/ / FaciltySiteResponse ',' xmlns = "http://yourNameSpaceLocation" ') > 0, failure and write your code accordingly.

Ben

Tags: Database

Similar Questions

  • Extraction of extensible in PL/SQL SOAP envelope group

    Hi all.

    I have the following in an XMLTYPE variable in PL/SQL SOAP envelope.

    <? XML version = "1.0" encoding = "UTF - 8"? >
    < env:Envelope xmlns:env = "http://schemas.xmlsoap.org/soap/envelope/" container = "http://www.w3.org/2001/XMLSchema" xmlns: xsi = "http://www.w3.org/2001/XMLSchema-instance" xmlns:ns0 = "http://elmarwsoicdvmws/types/" >
    < env:Body >
    < ns0:getDVMValuesResponseElement >
    < ns0:result >
    < ns0:dvmValues > 10 < / ns0:dvmValues >
    < ns0:dvmValues > 11 < / ns0:dvmValues >
    < ns0:dvmValues > 12 < / ns0:dvmValues >
    < ns0:errorText > Ok < / ns0:errorText >
    < ns0:errorCode > 0 < / ns0:errorCode >
    < / ns0:result >
    < / ns0:getDVMValuesResponseElement >
    < / env:Body >
    < / env:Envelope > '

    I can extract the code of error and ErrorText variable without too much effort (even if I don't know there are easier ways), but now I have to extract the repeating group of dvmValues in a variable of type table.

    Any ideas/code snippets would be greatly appreciated, as I've read tons of docs and half the time they are too complex or too simplistic (given my ns0: variables), and it seems that many functions I use have been depricated.

    Kind regards

    Elmar

    Hi Elmar,

    Using a separate function to analyze the individual nodes is not necessary.
    You can extract all with a single query, thus eliminating the need to access the same document several times.

    For example, once you have the content in the RESP xmltype variable, you can do:

    SQL> create type dvmValues_t as table of number;
      2  /
    
    Type created
    
    SQL> set serveroutput on
    SQL>
    SQL> DECLARE
      2
      3    resp         xmltype;
      4    v_errorText  varchar2(2000);
      5    v_errorCode  number;
      6    v_dvmValues  dvmValues_t;
      7
      8  BEGIN
      9
     10    resp := xmltype('
     11  
     12  
     13  
     14  
     15  10
     16  11
     17  12
     18  Ok
     19  0
     20  
     21  
     22  
     23  ');
     24
     25    select x.errorText
     26         , x.errorCode
     27         , cast(
     28             multiset(
     29               select dvmValue
     30               from xmltable('*' passing x.dvmValues
     31                                 columns dvmValue number path '.')
     32             )
     33             as dvmValues_t
     34           )
     35    into v_errorText
     36       , v_errorCode
     37       , v_dvmValues
     38    from xmltable(
     39           xmlnamespaces(
     40             'http://schemas.xmlsoap.org/soap/envelope/' as "env"
     41           , default 'http://elmarwsoicdvmws/types/'
     42           )
     43         , '/env:Envelope/env:Body/getDVMValuesResponseElement/result'
     44           passing resp
     45           columns
     46             errorText  varchar2(2000)  path 'errorText'
     47           , errorCode  number          path 'errorCode'
     48           , dvmValues  xmltype         path 'dvmValues'
     49         ) x
     50    ;
     51
     52    dbms_output.put_line('Error Text = ' || v_errorText);
     53    dbms_output.put_line('Error Code = ' || v_errorCode);
     54
     55    for i in 1..v_dvmValues.count loop
     56      dbms_output.put_line('Value(' || to_char(i) || ') = ' || v_dvmValues(i));
     57    end loop;
     58
     59  END;
     60  /
    
    Error Text = Ok
    Error Code = 0
    Value(1) = 10
    Value(2) = 11
    Value(3) = 12
    
    PL/SQL procedure successfully completed
     
    
  • How to see the response SOAP envelope full of BPEL

    Is it possible to see the full answer of BPEL (header SOAP + SOAP Body) in Enterprise Manager? As in path of Flow, I find that the value of the output variable.

    I don't think so there is an option to display the full message of EM, but you can check out the following blog to record the complete message in the log file.

    http://www.albinsblog.com/2012/10/getting-SOAP-envelope-of.html#.UyAcAPmSySo

    Concerning

    Albin I

    http://www.albinsblog.com/

  • REST base BSF calls returns with SOAP envelope Addressing WSA namespaces

    We expose the OSB (sampleREST) Proxy service as a RESTful service that accepts requests HTTP (GET, POST etc.).
    For the HTTP GET method, the proxy service called BPEL process synchronous Composite SOA (HelloWorldProject).

    The HelloWorldProject is a simple synchronous BPEL process that returns the response in the form of "Namaste, < < nom_entree > >.

    OSB HTTP GET request:

    http:// < < hostname > >: < < port > > / sampleREST/proxy/sampleREST

    Answer:

    <? XML version = "1.0" encoding = "UTF-8"? >
    " < processResponse xmlns =" http://xmlns.Oracle.com/MySOAApplication/HelloWorldProject/HelloWorldBPEL "xmlns:env =" http://schemas.xmlsoap.org/soap/envelope/ "xmlns:wsa =" http://www.w3.org/2005/08/Addressing "> "
    < result > Namaste, nanan < / result >
    < / processResponse >

    Description of the problem:

    In response, there are 3 namespaces,
    ( 1) xmlns = "http://xmlns.oracle.com/MySOAApplication/HelloWorldProject/HelloWorldBPEL"(ce n'est PAS le problème) "
    ( 2) xmlns:env = 'http://schemas.xmlsoap.org/soap/envelope/"(c'est le problème) "
    ( 3) xmlns:wsa = 'http://www.w3.org/2005/08/addressing"(c'est le problème) "

    For a response from REST, we expect the CORRECT answer

    [Envelope response soap CONTAINER AND wsa address namaspaces]

    <? XML version = "1.0" encoding = "UTF-8"? >
    " < processResponse xmlns =" http://xmlns.Oracle.com/MySOAApplication/HelloWorldProject/HelloWorldBPEL "> "
    < result > Namaste, nanan < / result >
    < / processResponse >

    I downloaded the Code from the OSB project.

    How do I get the answer REMAINS without SOAP ENVELOPE and NAMES ADDRESSING WSA namespaces?

    Thank you very much
    Nagaraj donna
    + 91-7387483335

    Hi all

    ATLAST, Oracle has provided a fix for this problem. I had raised SR with MOS.

    PFB the SR details to download the fix for this bug fix.

    Calls for expressions of OSB with SOAP and envelope WSA dealing of namespaces (Doc ID 1635230.1) is STILL based

    I hope this helps.

    Many thanks to all for your continued support and suggestions.

    Thank you very much

    Nagaraj donna

    + 91-7387483335

  • Suggestion: Add option to Soap envelopes to separate the dump file

    Currently, the Onyx log exports all envelopes in the journal of general Onyx.

    It's ok in most cases, but sometimes, it would be useful to be able to empty the Soap envelopes in a separate file.

    Type of a SOAP file 'raw '.

    ____________

    Blog: LucD notes

    Twitter: lucd22

    Hi LucD,

    Thanks for the suggestion! Similar functionality is already planned for a future release. It will provide easier access to the raw SOAP messages.

    Kind regards

    Ignat

  • Add the SOAP request envelope?

    Hello

    I am trying to invoke a SOAP request for a customer and the error by the web service response is:

    " < = xmlns:soapenv soapenv:Envelope ' http://schemas.xmlsoap.org/SOAP/envelope/ ">

    < soapenv:Body >

    < soapenv:Fault >

    < faultcode > server < / faultcode >

    < faultstring > org.apache.xmlbeans.XmlException: envelope SOAP missing/invalid, expecting [{http://schemas.xmlsoap.org/soap/envelope/} envelope] < / faultstring >

    < / soapenv:Fault >

    < / soapenv:Body >

    < / soapenv:Envelope >

    With the help of the SOAPInterceptor I can view the query sent to the server. If I take this exit, add manually the code below and send it to the web service using SoapUI receives the correct answer:

    " < envelope soap: xmlns:soap = ' http://schemas.xmlsoap.org/SOAP/envelope/ ">

    < soap: Body >

    .. generated .vCO request XML...

    < / soap: Body >

    < / envelope soap: >

    How can I add the SOAP envelope to the request? The code used in the Orchestrator workflow is the standard code generated by him "generate a new workflow to a SOAP operation', with the SOAPInterceptor added.

    Thank you

    Sam

    OK, I was wrong on several levels, in order to avoid misleading anyone:

    If you use the SOAPInterceptor class and the output XML body, is THAT the body you see - so of course, I do not see the envelope and have to add manually in SoapUI - this is not a fault but mine vCO!

    This was solved by logging into the web page of vCO admin and by setting the level of record to 'DEBUG' - it issued a much more usable error message, which leads me to the real problem. The WSDL returned a short name for the host that is running the web service - unit vCO which serves as endpoint and could not resolve the host name, so the script has failed. Change the web service to respond with its IP address meant orchestrator could communicate properly.

  • An unexpected element tag ' SOAP - ENV:Envelope "view

    Hello

    We get this error message during each request, we try to send via gSOAP:

    An unexpected element tag ' SOAP - ENV:Envelope "view

    Could someone explain to me, why I get this error?

    Here's the request:

    POST /sdk HTTP/1.1
    Host: vmware - test.boreus.de
    User-Agent: gSOAP/2.8
    Content-Type: application/soap + xml; charset = utf-8; action = "" urn: vim25 / 5.0 ""
    Content-Length: 551
    Connection: close
    Accept-Encoding: gzip, deflate
    SOAPAction: "urn: vim25 / 5.0.

    <? XML version = "1.0" encoding = "UTF-8"? >
    < SOAP - ENV:Envelope

    " xmlns:SOAP - ENV =" http://www.w3.org/2003/05/soap-envelope "xmlns:SOAP - ENC =" " http://www.w3.org/2003/05/soap-encoding "

    " xmlns: xsi =" http://www.w3.org/2001/XMLSchema-instance "

    " container = ' http://www.w3.org/2001/XMLSchema "xmlns:ns1 =" urn: vim25 "> < SOAP - ENV:Body > "

    < ns1:RetrieveServiceContent xsi: type = "ns1:RetrieveServiceContentRequestType" >

    < ns1:_this xsi: type = "ns1:ManagedObjectReference" type = "ServiceInstance" > ServiceInstance < / ns1:_this >

    < / ns1:RetrieveServiceContent >

    < / SOAP - ENV:Body >

    < / SOAP - ENV:Envelope >

    And here's the answer:

    HTTP/1.1 500 Internal Server Error
    Date: Wednesday, September 7, 2011 16:51:10 GMT
    Set-Cookie: vmware_soap_session = "524dac01-d304-ac9d-c557-34839dde76ac"; Path = /; HttpOnly;
    Cache-Control: no cache
    Connection: close
    Content-Type: text/xml; charset = utf-8
    Content-Length: 565

    <? XML version = "1.0" encoding = "UTF-8"? >
    " < = xmlns:soapenc soapenv:Envelope ' http://schemas.xmlsoap.org/SOAP/encoding/ "
    ' xmlns:soapenv = ' http://schemas.xmlsoap.org/SOAP/envelope/ "
    " container = ' http://www.w3.org/2001/XMLSchema "
    " xmlns: xsi =" http://www.w3.org/2001/XMLSchema-instance ">
    < soapenv:Body >
    < soapenv:Fault >
    ClientFaultCode < faultcode > < / faultcode >
    < faultstring >
    An unexpected element tag & quot; SOAP - ENV:Envelope & quot; view

    When parsing HTTP request before the method was determined
    on line 1, column 0 < / faultstring >
    < / soapenv:Fault >
    < / soapenv:Body >
    < / soapenv:Envelope >

    I don't really know if it's the reason either, but it was the first thing that comes to mind.  I have not seen this error, but I confess that I do not have a lot of work gsoap.

  • parsing a SOAP response

    Hi all

    I need to analyze this below the answer... but have no idea

    http://schemas.xmlsoap.org/soap/envelope/">
      
         http://tempuri.org">
            http://schemas.microsoft.com/dynamics/2008/01/documents/EmpltableWS">
               Original
               ceu
               
                  <_DocumentHash>30a13deb4619490c0fd70a5e56e70ad1
                  00:00:00
                  00:00:00
                  Admin
                  Contoso Enterprise
                  
                     060
                     0201
                     Site1
                     1000
                     1000
                  
                  [email protected]
                  No
                  Male
                  1000
                  Charlie Carson
                  Active
                  04
                  No
                  No
                  No
                  false
                  2013-01-01
                  0559999999
                  No
                  No
                  590
                  Bank
                  04999999
                  MGT. President BDM
                  5637144576
                  1955879158
                  Julia Funderburk
                  No
                  Employed
                  No
                  President-BDM
                  Yes
                  Yes
               
            
         
      
    
    

    On the response from the service I'm cela suite

    WebService Sub:{nServiceResponse()}

    "qDebug() < "responce="" data="" main=""> "< response.returnvalue().tostring();=""  ="" this="" value="" is="">

    parseEmployeProfile (response.returnValue ());

    }

    voidPMOwebservice:arseEmployeProfile (constQtSoapType & data) {}

    "qDebug() < "responce="" udatat="" after="" sending="" to="" parse=""> "< data["docpurpose"].tostring();="" this="" value="" i="" am="">

    QString Montana = data.toString ();

    JDA JsonDataAccess;

    QVariant jda.loadFromBuffer (mData) = qtData;

    const mapRoot =() qtData.value QVariantMap;

    const QVariantMap map = mapRoot.value("EmplTable",_"").toMap();

    QString DocPurpose = map.value("DocPurpose",_"").toString();   This value is also empty

    }

    Do not have idea how to analyze this complex response...

    waiting for your excellent response...

    Thanks in advnace.

    Hello

    Thanks for the reply...

    could you please show me an example on how to use this

    QtSoapStruct &soapStruct = (QtSoapStruct &) resp.method();int version = soapStruct["Version"].toInt();QtSoapArray &attributes = (QtSoapArray &) soapStruct["Attributes"];for (int i = 0; i < attributes.count(); ++i) {    QtSoapStruct item = (QtSoapStruct&) attributes[i];    QString attributeName = item["Attributename"].toString().toLower();    QString objectName = item["Objectname"].toString();    QString objectValue = item["Value"].toString();
    

    I'm new to the blackberry development...

    Example of ways... Use the attributes and the name of the object of the soap response that I posted previously...

    Thanks in advance...

  • How to parse a XML SOAP output and load table oracle9i

    Here's the output SOAP response and I need to load the data into the tables in oracle 9i database.
    I'm able to analyze the ordinary XML without namespace, but impossible to analyze the data of the namespaces.
    I could use some help in the analysis of this XML file.
    < xmlns:s s: Envelope = "http://schemas.xmlsoap.org/soap/envelope/" xmlns:u = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" >
    < s:Header >
    < o: Security s:mustUnderstand = "1" xmlns:o = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" >
    < u: Timestamp u: Id = "_0" >
    < u: created > 2011 - 11 - 04T 23: 16:08.437Z < / u: created >
    < u: expires > 2011 - 11 - 04T 23: 21:08.437Z < / u: expires >
    < / u: Timestamp >
    < / o: Security >
    < / s:Header >
    < Body >
    < AssetGetListResponse xmlns = "http://dev.services.xerox.com" >
    < AssetGetListResult xmlns: a = "http://schemas.datacontract.org/2004/07/Xerox.MPS" xmlns:i = "http://www.w3.org/2001/XMLSchema-instance" >
    < a: AssetFeed >
    < a: AccountID > de5862bf-f223-e011-bd3b-0024e861b15c < / a: AccountID >
    < a: AccountName > MPS-API Sandbox < / has: AccountName >
    < a: AssetID > ecf1545a-f1e9-e011-8a8a-0024e861b15c < / a: AssetID >
    < a: AssetNumber > 57119B 28 < / a: AssetNumber >
    < a: AssetTag3rdParty i: nil = "true" / >
    < a: ChargebackCodeID > 1a5962bf-f223-e011-bd3b-0024e861b15c < / a: ChargebackCodeID >
    < a: ContractNumber i: nil = "true" / >
    < a: ContractTypeDescription i: nil = "true" / >
    < a: i: Nile ControlID = "true" / >
    < a: group i: nil = "true" / >
    < a: GroupID i: nil = "true" / >
    < a: InScope > false < / has: InScope >
    < a: MACAddress > 0000AA713E97 < / a: MACAddress >
    < a: manufacturer > Xerox < / a: manufacturer >
    < a: model > WorkCentre Pro 265 < / a: model >
    < has: ModifiedDate > 2011 - 11 - 02T 16: 52:12.947Z < / a: ModifiedDate >
    < a: PricePlanID > c25a62bf-f223-e011-bd3b-0024e861b15c < / a: PricePlanID >
    < a: SerialNumber > UTU101993N < / a: SerialNumber >
    < a: VersionNumber > 634558495329470000 < / a: VersionNumber >
    < / a: AssetFeed >
    < a: AssetFeed >
    < a: AccountID > de5862bf-f223-e011-bd3b-0024e861b15c < / a: AccountID >
    < a: AccountName > MPS-API Sandbox < / has: AccountName >
    < a: AssetID > b33b5160-f1e9-e011-8a8a-0024e861b15c < / a: AssetID >
    < a: AssetNumber > 7EE42ADC < / a: AssetNumber >
    < a: AssetTag3rdParty i: nil = "true" / >
    < a: ChargebackCodeID > 1a5962bf-f223-e011-bd3b-0024e861b15c < / a: ChargebackCodeID >
    < a: ContractNumber i: nil = "true" / >
    < a: ContractTypeDescription i: nil = "true" / >
    < a: i: Nile ControlID = "true" / >
    < a: group i: nil = "true" / >
    < a: GroupID i: nil = "true" / >
    < a: InScope > false < / has: InScope >
    < a: MACAddress > 0800379B4C2A < / a: MACAddress >
    < a: manufacturer > Xerox < / a: manufacturer >
    < a: model > WorkCentre 7428 < / a: model >
    < has: ModifiedDate > 2011 - 11 - 02T 16: 52:14.383Z < / a: ModifiedDate >
    < a: PricePlanID > c25a62bf-f223-e011-bd3b-0024e861b15c < / a: PricePlanID >
    < a: SerialNumber > PBB015012 < / a: SerialNumber >
    < a: VersionNumber > 634558495343830000 < / a: VersionNumber >
    < / a: AssetFeed >
    < / AssetGetListResult >
    < / AssetGetListResponse >
    < / Body >
    < / s: Envelope >

    That's what I tried.

    declare
    lp_parser xmlParser.Parser;
    lx_xmldoc xmlDom.DOMDocument;

    ln_doc_node xmlDom.DOMNode;

    lnl_product xmlDom.DOMNodeList;
    lnl_meter xmlDom.DOMNodeList;
    ln_product xmlDom.DOMNode;
    ln_meter xmlDom.DOMNode;
    li_product_cnt NUMBER;
    li_product_max NUMBER;
    li_meter_cnt NUMBER;
    li_meter_max NUMBER;
    lnl_asset_meter_nodes xmldom. DOMNodeList;
    ln_asset_meter_node xmldom. DOMNode;

    ls_batch_number VARCHAR2 (30);
    ldt_proc_dt DATE;
    ls_batch_item VARCHAR2 (30);
    ls_place_id place.place_id%TYPE;
    ls_product_id product.product_id%TYPE: = ' ';
    ls_contract_id contract.contract_id%TYPE;
    li_contract_version contract.contract_version%TYPE;
    li_contract_sequence contr_product.sequence%TYPE;
    ls_meter_id meter_log.meter_id%TYPE;
    ls_read_type meter_log.read_type%TYPE;
    ldt_reading_dt meter_log.reading_dt%TYPE;
    li_meter_value meter_log.meter_value%TYPE;
    li_adjust_copies meter_log.meter_value%TYPE;
    ls_meter_type VARCHAR2 (20);
    ls_serial_id product.serial_id%TYPE;
    ls_meter_read_type VARCHAR2 (50);

    invalid_parsing EXCEPTION;
    PRAGMA EXCEPTION_INIT(invalid_parsing,-20100);

    BEGIN
    FOR meter_xml_rec IN (SELECT SOAP_RESPONSE
    Of insert_table
    WHERE call_id = 2) LOOP
    lp_parser: = xmlparser.newParser;
    xmlparser.parseClob (lp_parser, meter_xml_rec SOAP_RESPONSE);
    lx_xmldoc: = xmlparser.getDocument (lp_parser);
    xmlparser.freeParser (lp_parser);

    ln_doc_node: = xmlDom.makeNode (lx_xmldoc);
    ls_batch_number: = xslProcessor.valueOf (ln_doc_node, 'AssetGetListResponse, AssetGetListResult, AssetFeed, AccountID');

    lnl_product: = xslprocessor.selectNodes (ln_doc_node, ' AssetGetListResponse/AssetGetListResult/a: AssetFeed');
    li_product_max: = xmlDom.getLength (lnl_product)-1;
    FOR li_product_cnt IN 0.li_product_max LOOP
    ln_product: = xmlDom.item (lnl_product, li_product_cnt);

    ls_batch_item: = xslProcessor.valueOf (ln_product, 'AccountName');

    END LOOP;

    END LOOP;
    END;
    OUTPUT:

    =========================================
    15:32:41 *.
    * 15:32:41 ORA-20100: error occurred when processing: Namespace prefix "a" used but not declared.* *.
    15:32:41 ORA-06512: at "SYS." XSLPROCESSOR', line 22
    15:32:41 ORA-06512: at "SYS." XSLPROCESSOR", line 502
    15:32:41 ORA-06512: at line 50
    15:32:41 * script is stopped because of error *.
    Execute SQL Editor in end 15:32:41

    Hello

    Something like this:

    ...
    
    lnl_product := xslprocessor.selectNodes(
                     ln_doc_node
                   , '/s:Envelope/s:Body/AssetGetListResponse/AssetGetListResult/a:AssetFeed'
                   , 'xmlns:s="http://schemas.xmlsoap.org/soap/envelope/", xmlns="http://dev.services.xerox.com", xmlns:a="http://schemas.datacontract.org/2004/07/Xerox.MPS"'
                   );
    
    li_product_max := xmlDom.getLength(lnl_product)-1;
    
    FOR li_product_cnt IN 0..li_product_max LOOP
    
      ln_product := xmlDom.item(lnl_product, li_product_cnt);
      ls_batch_item := xslProcessor.valueOf(ln_product, 'a:AccountName', 'xmlns:a="http://schemas.datacontract.org/2004/07/Xerox.MPS"');
    
    END LOOP;
    
    ...
    

    Or, using a single query:

    SQL> SELECT extractValue(value(x), '/AssetFeed/AccountID', 'xmlns="http://schemas.datacontract.org/2004/07/Xerox.MPS"') as AccountID
      2       , extractValue(value(x), '/AssetFeed/AccountName', 'xmlns="http://schemas.datacontract.org/2004/07/Xerox.MPS"') as AccountName
      3       , extractValue(value(x), '/AssetFeed/AssetID', 'xmlns="http://schemas.datacontract.org/2004/07/Xerox.MPS"') as AssetID
      4       , extractValue(value(x), '/AssetFeed/AssetNumber', 'xmlns="http://schemas.datacontract.org/2004/07/Xerox.MPS"') as AssetNumber
      5       , extractValue(value(x), '/AssetFeed/SerialNumber', 'xmlns="http://schemas.datacontract.org/2004/07/Xerox.MPS"') as SerialNumber
      6  FROM temp_table t
      7     , TABLE(
      8         XMLSequence(
      9           EXTRACT(
     10             XMLType(t.soap_response)
     11           , '/s:Envelope/s:Body/AssetGetListResponse/AssetGetListResult/a:AssetFeed'
     12           , 'xmlns:s="http://schemas.xmlsoap.org/soap/envelope/", xmlns="http://dev.services.xerox.com", xmlns:a="http://schemas.datacontract.org/2004/07/Xerox.MPS"'
     13           )
     14         )
     15       ) x
     16  WHERE t.call_id = 2
     17  ;
    
    ACCOUNTID                                      ACCOUNTNAME           ASSETID                                   ASSETNUMBER    SERIALNUMBER
    ---------------------------------------------- --------------------- ----------------------------------------- -------------- ---------------
    de5862bf-f223-e011-bd3b-0024e861b15c           MPS-API Sandbox       ecf1545a-f1e9-e011-8a8a-0024e861b15c      57119B28       UTU101993N
    de5862bf-f223-e011-bd3b-0024e861b15c           MPS-API Sandbox       b33b5160-f1e9-e011-8a8a-0024e861b15c      7EE42ADC       PBB015012
     
    
  • Unable to parse the soap response if the response contains several objects

    Hello

    I am able to analyze the SAOP response.
    but I do not know how to parse for multiple objects in the entry. could you please check with below, which must analyze. I provided 3 objects of entry in the SOAP, but it should work for many also. and if we can analyze the length 32767 morethen clob?
    Please help it our of here.


    response_env: =' < soapenv:Envelope = "http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenv >
    < soapenv:Body >
    < UserInfoObjResponse xmlns:axis2ns1 = "http://www.test.com/services" >
    < axis2ns1:FirstName > first name out < / axis2ns1:FirstName >
    < axis2ns1:LastName > last exit name < / axis2ns1:LastName >
    < axis2ns1:ErrorDescription / >
    < / UserInfoObjResponse >
    < UserInfoObjResponse xmlns:axis2ns1 = "http://www.test.com/services" >
    < axis2ns1:FirstName > first name out < / axis2ns1:FirstName >
    < axis2ns1:LastName > last exit name < / axis2ns1:LastName >
    < axis2ns1:ErrorDescription / >
    < / UserInfoObjResponse >
    < UserInfoObjResponse xmlns:axis2ns1 = "http://www.test.com/services" >
    < axis2ns1:FirstName > first name out < / axis2ns1:FirstName >
    < axis2ns1:LastName > last exit name < / axis2ns1:LastName >
    < axis2ns1:ErrorDescription / >
    < / UserInfoObjResponse >
    < / soapenv:Body >
    < / soapenv:Envelope > ';
    -----------------------------------------
    declare
    CLOB response_env;
    v_xml XMLTYPE.
    l_user_first_name varchar2 (1000);
    l_user_last_name varchar2 (100);
    l_error_value varchar2 (100);
    NS varchar2 (200): = 'xmlns:soapenv = 'http://schemas.xmlsoap.org/soap/envelope/' xmlns:axis2ns1 = "http://www.test.com/services" ';
    Start
    response_env: =' < soapenv:Envelope = "http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenv >
    < soapenv:Body >
    < UserInfoObjResponse xmlns:axis2ns1 = "http://www.test.com/services" >
    < axis2ns1:FirstName > first name out < / axis2ns1:FirstName >
    < axis2ns1:LastName > last exit name < / axis2ns1:LastName >
    < axis2ns1:ErrorDescription / >
    < / UserInfoObjResponse >
    < / soapenv:Body >
    < / soapenv:Envelope > ';

    dbms_output.put_line (' length to ask:' | length (response_env));
    -dbms_output.put_line (' ask: ' | response_env);

    v_xml: = XMLTYPE (response_env);

    Select EXTRACTVALUE(v_xml,'/soapenv:Envelope/soapenv:Body/UserInfoObjResponse/axis2ns1:FirstName',ns),
    EXTRACTVALUE(v_xml,'/soapenv:Envelope/soapenv:Body/UserInfoObjResponse/axis2ns1:LastName',NS),
    EXTRACTVALUE(v_xml,'/soapenv:Envelope/soapenv:Body/UserInfoObjResponse/axis2ns1:ErrorDescription',NS)
    in l_user_first_name, l_user_last_name, l_error_value
    Double;

    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;
    --------------------------------------------
    SQL> declare
       response_env   clob
          := '
    
    
    1. First Name Output
    Last Name Output
    
    
    
    2. First Name Output
    Last Name Output
    
    
    
    3. First Name Output
    3. Last Name Output
    
    
    
    ';
    begin
       for c in (select x.*
                   from xmltable (
                           xmlnamespaces (
                              'http://schemas.xmlsoap.org/soap/envelope' as "x",
                              'http://www.test.com/services' as "axis2ns1"),
                           '*'
                           passing xmltype (response_env).
                                   extract (
                                      '//UserInfoObjResponse',
                                      'xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:axis2ns1="http://www.test.com/services"')
                           columns firstname varchar2 (25) path 'axis2ns1:FirstName',
                                   lastname varchar2 (25) path 'axis2ns1:LastName',
                                   errordescription varchar2 (25) path 'axis2ns1:ErrorDescription') x)
       loop
          dbms_output.put (rpad(c.firstname,30));
          dbms_output.put (rpad(c.lastname,30));
          dbms_output.put_line (rpad(c.errordescription,30));
       end loop;
    end;
    /
    1. First Name Output          Last Name Output
    2. First Name Output          Last Name Output
    3. First Name Output          3. Last Name Output
    PL/SQL procedure successfully completed.
    
  • How to analyze the results of GetSOAPRequest

    Hello

    Can someone help me, how can I analyze the result GetSOAPRequest's next? The following xml code is the example that I try to analyse. Thank you.

    <? XML version = "1.0" encoding = "UTF-8"? >
    "< xmlns:soap: envelope soap =" http://schemas.xmlsoap.org/soap/envelope/ "> "
    < soap: Body >
    "< getCountriesListResponse xmlns =" http://www.voxbone.com/VoxService "> "
    < country >
    "< ns1:Country xmlns:ns1 =" http://containers.services.webservices.voxbone "> "
    "< availableDidsCount xmlns =" http://containers.services.webservices.voxbone "> 79 < / availableDidsCount > "
    "< countryCodeA2 xmlns =" http://containers.services.webservices.voxbone "> AR < / countryCodeA2 > "
    "< countryName xmlns =" http://containers.services.webservices.voxbone "> ARGENTINA < / countryName > "
    "< countryPhoneCode xmlns =" http://containers.services.webservices.voxbone "> 54 < / countryPhoneCode > "
    < / ns1:Country >
    "< ns1:Country xmlns:ns1 =" http://containers.services.webservices.voxbone "> "
    "< availableDidsCount xmlns =" http://containers.services.webservices.voxbone "> 73 < / availableDidsCount > "
    "< countryCodeA2 xmlns =" http://containers.services.webservices.voxbone "> BR < / countryCodeA2 > "
    "< countryName xmlns =" http://containers.services.webservices.voxbone "> BRAZIL < / countryName > "
    "< countryPhoneCode xmlns =" http://containers.services.webservices.voxbone "> 55 < / countryPhoneCode > "
    < / ns1:Country >
    < / country >
    < / getCountriesListResponse >
    < / soap: Body >

    Hi Mike,.

    I got to work with this code snippet.


    Thank you very much!

  • How to define soap headers in the soap request using qtsoap?

    Hi all!

    I need to add a soap from the soap request header. I use qtsoap to post the soap request. It comes to my complete application. How can I add headers in the code...!

    
    http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
      
        http://tempuri.org/">
          string
          string
        
      
      
        http://tempuri.org/">
          string
        
      
    
    

    I tried like this:

    QtSoapMessage request;
    
        QtSoapStruct soap_struct(QtSoapQName("SecureSoapHeader", "http://tempuri.org/"));
    soap_struct.insert(new QtSoapSimpleType(QtSoapQName("Platform"), "BlackBerry"));
        soap_struct.insert(new QtSoapSimpleType(QtSoapQName("AuthToken"), "4A2EDCDA-E5A9-4E77-B41A-F1C1FF15A645"));
    
        request.addHeaderItem(&soap_struct);
    
        request.setMethod("GetCitiesByCountryCode", "http://tempuri.org/");
    
        request.addMethodArgument("countryCode", "", "IN");
        http.setHost("dev4.winitsoftware.com");
        http.setAction("http://tempuri.org/GetCitiesByCountryCode");
        http.submitRequest(request, "/EzeegoMiddleware/Services/HotelService.asmx");
    

    After the specification of it, the application closes...

    If anyone has tried it, help me please!

    Thank you.

    -Rezé

    Hello! I haven't used this API but I guess submitRequest is asynchronous.

    You create soap_struct on the stack (so it's a local variable).

    After the method submitRequest will end the service and all local variables will be destroyed, so the address passed to addHeaderItem will become invalid.

    Try to create soap_struct on the job:

    QtSoapStruct *soap_struct = new QtSoapStruct(...)
    soap_struct->insert(...);
    request.addHeaderItem(soap_struct);
    
  • Suffix call SOAP for BES etc.

    Hey. Normally, of course, you add a suffix to a URL for your connection by BES or BIS or something else, as follows:

    c = (HttpConnection) Connector.open (url + suffix + ";" ConnectionTimeout ="" + String.valueOf (m_InternetConnectionTimeout)(, 0, true); "

    But where does the suffix when you make a SOAP call, in order to choose BIS/BES/etc? The HTTPTransport constructor disliked the suffix- and may not enter the SOAP about thanks for any help,

    Justin

                            SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER12);
    
                            envelope.env = "http://www.w3.org/2003/05/soap-envelope";
                            envelope.xsi = SoapEnvelope.XSI1999;
                            envelope.xsd = SoapEnvelope.XSD1999;
                            envelope.bodyOut = so;   
    
                            String timeout = String.valueOf((int)(((double)m_InternetConnectionTimeout / 4) + (m_SOAPInternetConnectionTimeoutPerResult * numResultsPerSearchstring)));
                            HttpTransport soap = new HttpTransport("http://api.flickr.com/services/soap/;ConnectionTimeout=" + timeout);   // + GetSuffix() +
                            SoapObject result = null;
    
                            try {
                                soap.call("FlickrRequest", envelope);
    

    What do you mean by "disliked"? I use the suffix of connection with httptransport very well, it's usually just; deviceside = false

  • Cannot be getNodeWithProps. AppParameters treatment in the SOAP header error: AppParameters does not exist in the SOAP header.

    Hi all

    Cannot be getNodeWithProps. AppParameters treatment in the SOAP header error: AppParameters does not exist in the SOAP header.

    " < = xmlns:env env:Envelope ' http://schemas.xmlsoap.org/SOAP/envelope/ ' > < env:Header / > < env:Server env:Body > < env:Fault > < faultcode > < / faultcode > < faultstring > cannot getNodeWithProps.» AppParameters treatment in the SOAP header error: AppParameters does not exist in the SOAP header. "< / faultstring > < details > < DrmServiceException xmlns ="http://drm.webservices.epm.oracle"> < Message xmlns:ns2 ="http://drm.webservices.epm.oracle"xmlns =" "> cannot getNodeWithProps." AppParameters treatment in the SOAP header error: AppParameters does not exist in the SOAP header. "< / Message > < Code xmlns:ns2 ="http://drm.webservices.epm.oracle"xmlns =" "> 0 < / Code > < / DrmServiceException > < / details > < / env:Fault > < / env:Body > < / env:Envelope > "

    clues?

    Thank you

    Mady

    Hi Mady,

    Have you run a test of the DRM of this URL service section? Part of the SOAP message that must be sent to the web service DRM when calling the AppParameters is in the header of the SOAP message. This is the example that gives the URL:


    http://DRM.WebServices.EPM.Oracle">
    http://DRM.WebServices.EPM.Oracle ">http://localhost:5240 / Oracle/Drm/APIAdapter "
    http://DRM.WebServices.EPM.Oracle "> ProductVersion = 11.1.2 CultureName = US, TimeZoneOffset =-360"

    The error is just saying that the section of AppParamters doesn't seem to be there in the SOAP message that was received. How you call the web service DRM method that returns this error? It seems just that, however, it is called the AppParameters is missing in the SOAP message is sent to.

    Do you need some kind of common authentication method setting upward for Weblogic and Shared Services, but not necessarily OID. I mentioned a possibility without using an external LDAP directory here on a case where you set up a development environment Re: configuration of the DRM web service API

    Concerning

    Craig

  • Is it possible to send the response to the client with the SOAP header containing the user information in JAX - WS?

    Hello

    I use JDev 11.1.1.7.0 and Weblogic 10.3.

    I have a JAX - WS based web service on which authentication and authorization was in place and operational.

    The SOAP request carries information of SOAP header with the token of user name and password for authentication. Similarly the SOAP response can also transport header to the client information? So that the customer who receives the answer happens to knowledge of who he actually received the answer.

    Thanks in advance.

    Hi Harsha,

    Is quite easy to define soap headers in a response message soap envelope. No need to use handlers either. Please find the link that would be useful below.

    You must use the WebParam property and set the modes for messages (IN, OUT, INOUT) and you can pass multiple values JAX WS service using "javax.xml.ws.Holder".

    http://tomee.Apache.org/examples-trunk/WebService-holder/Readme.html

    Please find the sample and put interfaces implement the Web service for the same.

    Interface:

    @WebMethod (operationName = "GetItemDetails", action = "http://xmlns.org/ItemService/GetItemDetails/V1")

    Public Sub getItemDetails)

    @WebParam (name = "ItemCandListServiceMessage", targetNamespace = "http://xmlns.org/ItemCandList", partName is "ItemRequest" mode = Mode.IN) ItemCandListServiceMessageCmplxType itemRequest,.

    @WebParam (name = "ItemServiceMessage", targetNamespace = "http://xmlns.org/Item", partName is "ItemResponse" mode = Mode.OUT) owner itemResponse,.

    @WebParam (name = "ItemSOAPHeader", targetNamespace = "http://xmlns.org/ItemSOAPHeader", "ItemSOAPHeader" = partName, header = true, mode = Mode.INOUT) holder itemSOAPHeader)

    throws ItemFaultMessage

    ;

    Implementation:

    public void getItemDetails (ItemCandListServiceMessageCmplxType itemRequest, door itemResponse, door itemSOAPHeader) throw {ItemFaultMessage}

    itemResponse.value = objectFactory.createItemServiceMessageCmplxType ();

    itemSOAPHeader.value.setRequestId ("response");

    itemResponse.value = itemServiceBean.getItemDetails (itemRequest, itemSOAPHeader.value, itemResponse.value);

    }

Maybe you are looking for

  • Date order of email? Spare part

    2 questions. 1 why Thunderbird shows all it's email lists in reverse order by default? Certainly, everyone wants the most recent email to be at the top if you do not have to scroll all the way and that's the way everybody does because it makes sense.

  • AppleScript come into conflict with the constant "error" iTunes and "double".

    In AppleScript, the key word 'error' is a reserved word. Unfortunately iTunes also defines a constant named "error used as a possible value for example status track iCloud. For example the code such as: If the status of aTrack cloud is equal to then

  • Difficulty tab window so show images of webistes

    This Web https://support.mozilla.org/en-US/kb/thumbnails-on-new-tab-page-are-missing page does not solve my problem. Anyone know how to get your website to the images to display on the page of the new tab "tabs"? Using Windows 7 and XP, updated 20 FF

  • Newer systems as beautiful as Snow Leopard?

    My HP printer has been replaced under warranty.  It wouldn't work with my Snow Leopard operating system.  I had used the OS 10.6 since 2009.  In order to get functions limited to work with my iMac, I had to get a third-party driver.  HP technicians t

  • T61 screen

    Dear friends, is it normal for me to see that the color white for example looks like it has grain inside and seems to be a bit like gray-blue? I only mean if you observe it? It's very strange, and given that I don't have opportunity to compare with o