PLSQL web service returning multiple records

Hello,
I am trying to create a web service using oracle 11g which should be able to return multiple records.
Based on hints and code samples found on the internet here is my code :
CREATE OR REPLACE TYPE test_rec is OBJECT (
    s_nume_adre                    NUMBER ,
    c_eta_civi                     VARCHAR2(4 BYTE),
    l_nom1_comp                    VARCHAR2(40 BYTE),
    l_nom2_comp                    VARCHAR2(40 BYTE),
    l_nom3_comp                    VARCHAR2(40 BYTE),
    l_pren_comp                    VARCHAR2(30 BYTE),
    d_date_nais                    DATE);
CREATE OR REPLACE TYPE test_array AS TABLE OF test_rec;
CREATE OR REPLACE PACKAGE test_pkg AS
  function get_rows(snume_adre in number) return test_array;
END;
CREATE OR REPLACE PACKAGE BODY test_pkg AS
  function get_rows(snume_adre in number) return test_array is
    v_rtn   test_array := test_array(null);
    v_first boolean := true;
    cursor c_get_rows(snume_adre in number) is
      SELECT a.s_nume_adre,
             nvl(a.c_eta_civi, '') c_eta_civi,
             nvl(a.l_nom1_comp, '') l_nom1_comp,
             nvl(a.l_nom2_comp, '') l_nom2_comp,
             nvl(a.l_nom3_comp, '') l_nom3_comp,
             nvl(a.l_pren_comp, '') l_pren_comp,
             nvl(a.d_date_nais, to_date('01.01.1900', 'dd.mm.yyyy')) d_date_nais
    FROM bro.z45 a
  where a.s_nume_adre = snume_adre or snume_adre is null;
  begin
    for rec in c_get_rows(snume_adre) loop
      if v_first then
        v_first := false;
      else
        v_rtn.extend;
      end if;
    v_rtn(v_rtn.last) := test_rec(rec.s_nume_adre, rec.c_eta_civi, rec.l_nom1_comp, rec.l_nom2_comp,
                                rec.l_nom3_comp, rec.l_pren_comp, rec.d_date_nais);
    end loop;  
    return v_rtn;
  end;
END;
--select * from table (test_pkg.get_rows(null));
I am able to retrieve the data using the select.
However when I try to access its wsdl I get an error :
<soap:Envelope>
   <soap:Body>
      <soap:Fault>
         <faultcode>soap:Client</faultcode>
         <faultstring>Error processing input</faultstring>
         <detail>
            <OracleErrors></OracleErrors>
         </detail>
      </soap:Fault>
   </soap:Body>
</soap:Envelope>
If I comment the function call in the package declaration I get a "correct" wsdl :
<definitions name="GET_ROWS" targetNamespace="http://xmlns.oracle.com/orawsv/TEST/TEST_PKG/GET_ROWS" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://xmlns.oracle.com/orawsv/TEST/TEST_PKG/GET_ROWS" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
  <types>
    <xsd:schema targetNamespace="http://xmlns.oracle.com/orawsv/TEST/TEST_PKG/GET_ROWS" elementFormDefault="qualified">
      <xsd:element name="GET_ROWSInput">
        <xsd:complexType>
          </xsd:complexType>
      </xsd:element>
      <xsd:element name="GET_ROWSOutput">
        <xsd:complexType>
          </xsd:complexType>
      </xsd:element>
   </xsd:schema>
  </types>
  <message name="GET_ROWSInputMessage">
    <part name="parameters" element="tns:GET_ROWSInput"/>
  </message>
  <message name="GET_ROWSOutputMessage">
    <part name="parameters" element="tns:GET_ROWSOutput"/>
  </message>
  <portType name="GET_ROWSPortType">
  <operation name="GET_ROWS">
      <input message="tns:GET_ROWSInputMessage"/>
      <output message="tns:GET_ROWSOutputMessage"/>
    </operation>
  </portType>
  <binding name="GET_ROWSBinding" type="tns:GET_ROWSPortType">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="GET_ROWS">
      <soap:operation soapAction="GET_ROWS"/>
      <input>
        <soap:body parts="parameters" use="literal"/>
      </input>
      <output>
        <soap:body parts="parameters" use="literal"/>
      </output>
    </operation>
  </binding>
  <service name="GET_ROWSService">
    <documentation>Oracle Web Service</documentation>
    <port name="GET_ROWSPort" binding="tns:GET_ROWSBinding">
       <soap:address location="http://server.domain.ch:8080/orawsv/TEST/TEST_PKG/GET_ROWS"/>
     </port>
  </service>
</definitions>
Any hint as how to create and access pl sql web service returning multiple rows?
I don't use java and don't have access to tools like JDeveloper.
Thanks!

The actual issue is that collection types are not supported for return parameters.
The solution is to wrap the collection into another object.
Here's a working example based on your settings :
CREATE OR REPLACE TYPE test_rec is OBJECT ( 
  empno  number(4)
, ename  varchar2(10)
, hiredate date
CREATE OR REPLACE TYPE test_array AS TABLE OF test_rec; 
CREATE OR REPLACE TYPE test_array_wrapper is OBJECT ( arr test_array );
CREATE OR REPLACE PACKAGE test_pkg AS 
  function get_rows(p_deptno in number) return test_array_wrapper; 
END; 
CREATE OR REPLACE PACKAGE BODY test_pkg AS 
  function get_rows(p_deptno in number) return test_array_wrapper is 
    results  test_array; 
  begin 
    select test_rec(empno, ename, hiredate)
    bulk collect into results
    from scott.emp
    where deptno = p_deptno;    
    return test_array_wrapper(results); 
  end; 
END; 
The wsdl is then generated correctly :
SQL> select httpuritype('http://DEV:dev@localhost:8080/orawsv/DEV/TEST_PKG/GET_ROWS?wsdl').getxml() from dual;
HTTPURITYPE('HTTP://DEV:DEV@LOCALHOST:8080/ORAWSV/DEV/TEST_PKG/GET_ROWS?WSDL').GETXML()
<definitions name="GET_ROWS" targetNamespace="http://xmlns.oracle.com/orawsv/DEV/TEST_PKG/GET_ROWS" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://xmlns.oracle.com/orawsv/DEV/TEST_PKG/GET_
ROWS" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
  <types>
    <xsd:schema targetNamespace="http://xmlns.oracle.com/orawsv/DEV/TEST_PKG/GET_ROWS" elementFormDefault="qualified">
      <xsd:element name="CTEST_ARRAY_WRAPPER-GET_ROWSInput">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="P_DEPTNO-NUMBER-IN" type="xsd:double"/>
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
      <xsd:element name="GET_ROWSOutput">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="RETURN" type="tns:TEST_ARRAY_WRAPPERType"/>
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
      <xsd:complexType name="TEST_ARRAY_WRAPPERType">
        <xsd:sequence>
          <xsd:element name="TEST_ARRAY_WRAPPER">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="ARR">
                  <xsd:complexType>
                    <xsd:sequence>
                      <xsd:element name="TEST_REC" type="tns:TEST_REC_IntType" maxOccurs="unbounded" minOccurs="0"/>
                    </xsd:sequence>
                  </xsd:complexType>
                </xsd:element>
              </xsd:sequence>
            </xsd:complexType>
          </xsd:element>
        </xsd:sequence>
      </xsd:complexType>
      <xsd:complexType name="TEST_REC_IntType">
        <xsd:sequence>
          <xsd:element name="EMPNO" type="xsd:double"/>
          <xsd:element name="ENAME">
            <xsd:simpleType>
              <xsd:restriction base="xsd:string">
                <xsd:maxLength value="10"/>
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:element>
          <xsd:element name="HIREDATE" type="xsd:date"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:schema>
  </types>
  <message name="GET_ROWSInputMessage">
    <part name="parameters" element="tns:CTEST_ARRAY_WRAPPER-GET_ROWSInput"/>
  </message>
  <message name="GET_ROWSOutputMessage">
    <part name="parameters" element="tns:GET_ROWSOutput"/>
  </message>
  <portType name="GET_ROWSPortType">
    <operation name="GET_ROWS">
      <input message="tns:GET_ROWSInputMessage"/>
      <output message="tns:GET_ROWSOutputMessage"/>
    </operation>
  </portType>
  <binding name="GET_ROWSBinding" type="tns:GET_ROWSPortType">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="GET_ROWS">
      <soap:operation soapAction="GET_ROWS"/>
      <input>
        <soap:body parts="parameters" use="literal"/>
      </input>
      <output>
        <soap:body parts="parameters" use="literal"/>
      </output>
    </operation>
  </binding>
  <service name="GET_ROWSService">
    <documentation>Oracle Web Service</documentation>
    <port name="GET_ROWSPort" binding="tns:GET_ROWSBinding">
      <soap:address location="http://localhost:8080/orawsv/DEV/TEST_PKG/GET_ROWS"/>
    </port>
  </service>
</definitions>

Similar Messages

  • BUG: Web service returns request XML as response when result too large

    Hi,
    sorry for cross-posting, but the Web Services forum seems to be quite abandoned and this is an urgent issue for me.
    I have a web service returning some records of a given type (created using JDeveloper 10.1.3.3). The running environment and the service implementation do not seem to make any difference, as the situation is the same whether running it in embedded OC4J or in AS 10.1.3.1, and whether it is generated from a PL/SQL procedure or a method of a plain Java class.
    The problem is that if the result of this web service is too large (contains a lot of records), then the processing halts in some Oracle class in some web service library, so not in a debuggable generated web service source or in the service implementation itself.
    I think that the XML processing halts because of a "java.lang.OutOfMemoryError: Java heap space".
    Then a more serious problem follows: the service doesn't return a fault message but the original request XML as a response. Obviously, this can lead to some really unexpected errors.
    To reproduce this error:
    1. Create a Java class with a method returning an array of an arbitrary type, of the size specified in an input parameter.
    2. Create a web service from this class.
    3. Call it multiple times increasing the size parameter in every call until you get back the request as response or any error message.
    For example:
    - if you test the web service using the web page generated to access the endpoint, then you can see the response XML - in case you don't get an Internal Server Error (Java heap space).
    - if you use a generated web service proxy for testing, then it will give an error saying "unexpected element name: expected={namespace}someOperationResponseElement
    actual={namespace}someOperationElement".
    Any ideas how to locate / solve this problem?
    Regards,
    Patrik

    Patrik,
    the usual recommendation is to try with 10.1.3.3 instead of 10.1.3.1 to exclude you are hunting down an already fixed issue. From what you describe, the error seems less JDeveloper related than OC4J or OracleAs.
    So in case it reproduces in 10.1.3.3 I suggest to create a testcase and open a service request with support, or try the OC4J forum in case its known there.
    Frank

  • Web services with multiple elements in the results

    We are using ASP.Net and LiveCycle Forms with LiveCycle Designer 7.0. LiveCycle forms is running on JBOSS (turnkey installation). Our problem is that if the web service returns multiple results e.g.
          £12.99
          Widget
          £0.99
          Grommett
    The form does not grow to accommodate the extra results. Has anyone had any experience of this issue. Adobe say it can be done but so far we have had no luck.

    <[email protected]> ha scritto nel messaggio <br />news:[email protected]..<br />> We are using ASP.Net and LiveCycle Forms with LiveCycle Designer 7.0. <br />> LiveCycle forms is running on JBOSS (turnkey installation). Our problem is <br />> that if the web service returns multiple results e.g.<br />> <products><br />>   <product><br />>      <price>£12.99</price><br />>      <description>Widget</description><br />>   </product><br />>   <product><br />>      <price>£0.99</price><br />>      <description>Grommett</description><br />>   </product><br />> </products><br />> The form does not grow to accommodate the extra results. Has anyone had <br />> any experience of this issue. Adobe say it can be done but so far we have <br />> had no luck.<br /><br />You have to create a subform that has flow content, then flag "repeat the <br />subform for each data item" (or something similar, I've not Designer <br />installed on this machine). Remember to save as dynamic PDF.<br /><br />Bye,<br />Alessio

  • How to return multiple record with Oracle Native Web Service?

    Dear all,
    I would like to know that the oracle native web service can be able to return multiple records to client or not?
    I successfully developed the oracle native web service for returning single record but the next challenge is to develop web service in order to return multiple record (like Employees data base on each department)
    Thank and Regards,
    Zenoni

    I successfully developed the oracle native web service for returning single record but the next challenge is to develop web service in order to return multiple record (like Employees data base on each department)You could return a list (multiple values/records) in XML format (using XMLType or CLOB), or CSV, or JSON, or whatever.
    function get_employees (p_department_id in number) return clob
    as
    begin
      return 'your_xml_string_here';
    end get_employees;It would be up to the client (the caller of the web service) to extract the values from whatever format you decide upon, of course.
    - Morten
    http://ora-00001.blogspot.com

  • Eclipelink plsql web services multiple operation

    Hi,
    In 11.1.2.2 jdev, I can generate a toplink/eclipse link plsql web services easily for one SQL (dbws).
    Can I change the web services to support multiple operations, each for different select sql?
    I've tried to changed the wsdl file to have multiple operations
    and amend eclipse link-dbws.XML to include multiple query tags.
    The web services can be run with multiple operation wsdl but the response of each operation
    (using Jdev http analyzer) return only the result of the first operaton.
    Can anyone help?
    Regards,
    Neln
    Edited by: Nelson Ng on Nov 10, 2012 8:45 PM

    Hi,
    I think you are asking for multiple select statements processed by a single TopLink DB Service Provider configuration. As far as I know its exactly one per project and service. However, as this feature is coming from EclipseLink you may want to verify it there
    Frank

  • The simplest way for plsql procedure to return multiple rows

    Hi,
    What is the simplest way for plsql procedure to return multiple rows (records). There are many combination of ways to do it but I am looking for a solution that is appropriate for plsql beginners. Many solutions use cursors, cursor variables, collections and more that kind of things that are complex on the face of it. Is it somehow possible to achieve the same with less effort?
    Sample query would be: SELECT * FROM EMPLOYEES;
    I want to use returned rows in APEX to compose APEX SQL(in that context plsql) report.
    It is enough to use just SELECT * FROM EMPLOYEES query in APEX but I want to use plsql procedure for that.
    Thank you!

    Hi,
    It depends :-).
    With +...that is appropriate for plsql beginners...+ in mind... it still depends!
    The list of techniques (ref cursors, cursor variables, collections, arrays, using explict SQL) you have referenced in your post can be made to work. but...
    +Is it somehow possible to achieve the same with less effort?+ Less effort : That needs to be defined (measured). Especially in the context of pl/sql beginners (who is a beginner?) .
    What is the level of "programming experience" ?
    What is the level of understanding of "Relational Result set" as processible in Oracle?
    If you are looking for
    Process_the_set_of rows_in APEX () kind of capabilitywhich "abstracts/hides" relation database from developers when working on relation database, it may not be the best approach (at least strategically). Because I believe it already is abstracted enough.
    I find REF CUROSOR most effective for such use, when the "begginer" has basic understanding of processing SQL result set .
    So in a nut shell, the techniques (that you already are familiar with) are the tools available. I am not aware of any alternative tools (in pure Oracle) that will simplify / hide basics from develpers.
    vr,
    Sudhakar B.

  • Web service with multiple out parameters

    Hi Developers,
    I have been playing around with som web services in the developer studio.
    I can create a webservice from a normal ejb.
    But i can only get one out parameter, which is the return parameter of the ejb.
    I tried to make an object to use as return parameter, but then i couldn't use the method for the web service.
    Can anyone tell me how to make a web service with multiple out parameters?
    Br Rasmus

    Hi Developers,
    I have the same question, is it possible to have multiple outgoing parameters?
    When not, does SAP Netweaver knows a IN-OUT parameter? Because I found on the internet that it is possible to have a IN-OUT parameter. But that was with the BEA Weblogic 8.x.
    When not, is then the only solution to return a object? With in this object all the parameters you want.
    Or otherwise is there a other workaround?
    Thanks in advance,
    Marinus Geuze

  • What happens when a OUT parameter of a web-service returns an empty string

    Hi,
    Any idea on how to deal with the situation when a web-service returns an empty string
    I get the following System Exception:-
    Caused by: java.lang.AssertionError: Attempt to set empty javaType to ticketResponse(out,0) :: fuego.type.FuegoClass$LazyRef@6770f2. It must be null or a valid java type.
    It therefore either expects a null value or a valid java type...
    Since it goes into a system exception, the activity is not completed and nothing is inserted into the web-service..
    How do we resolve this error inside of BPM?

    Thanks Ben for your replies.
    Before I attempt changing a VI that was written by a client and make a total mess of it, there's something I'd like to point out.
    I tried the re-entrant VI approach and that didn't go any further than the VIT approach, and probably for the same reason(s).
    The interesting part is that (with the VIT approach) the same VIT is called by another process and it works fine.  It is just for the process that has it appear within 2 sub-panels.  So the issue is related to having either having two instances spawn at once of the same VIT or it is related to the sub-panels.  I think it is the two instances (or copies of the VIT) that causes LV to caugh...
    So you are trying to tell me that the above description is accurate and it is because of the private methods...??...
    How would I "wrap" those private methods into public ones?  The seems to be a piece of this puzzle that I am not yet grasping..
    Thanks for your patience and help.
    RayR

  • Problem with CLOB in PLSQL Web Service.

    Hi-
    I have Oracle Package that accepts CLOB as IN parameter and another CLOB as an OUT parameter. I went thru the tutorial in how to publish a database
    PLSQL package as a web service with out any problem. I was able to publish and call successfully my PLSQL web service thru a browser and thru a simple C# application. It's been working fine until I receive an XML file which is bigger than 32766:
    java.sql.SQLException: setString can only process strings of less than 32766 chararacters at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:137)]
    JDeveloper version: JDeveloper 10g (10.1.2.2.0) Build 1929
    Oracle Application Server 10g
    I'm newbie in JDeveloper so any help is greatly appreciated.
    Thanks!

    well Shay,
    i've used JDev's tools to developer and to deploy the web service: the war and ear files are automatically generates you to the end of the process.
    I have included all the files java and the compiled classes, but I do not have files jar.
    But don't works: if i create only one java class with all code inside then it works fine!!
    Daniele

  • SQL Command returns multiple records, but I see only one record in report

    I work with Crystal Reports XI R2 SP3 and Oracle 10g R2 database.
    I have an SQL Command that returns multiple records. Command name is "CommDivisionNames" and it returns column "CommDivisionNames.DIVISION_NAME". When I place this field into report details section of the report, I can see all 10 records returned and this is how it should be. I actually need this field to be placed in the report header section, and when I place the field there, then I see only the first record. I set that field as "can grow = true". When I do "browse field data" for this field, I see that all 10 records are there, but only the first one is displayed in report header section.
    I thought that I can place SQL Command field anywhere on the report (page header, footer, details) and that it will always show all records that it returns from the database. Can that be done?
    My "main part" of the report returns different set of records, and that's what I have in "report details" section. I need this list of divisions to be in the report header section, so user can see that the report was executed for DivA, DivC, DivE.
    Thank you,
    Milan

    sharonamt:
    Users select divisions from parameter, but the parameter multi values are division_numbers (1,5,10), not division_names. Division_names are visible in parameter_prompt_window as description, but parameter remembers only numbers and I don't know how I can reuse division_names later in formula.
    I do join for division_numbers and make them into one string variable and pass to sub-report, but I think that I can only get these division_names by calling an SQL command or calling stored procedure.
    If I try to do join({MySQLcommand.DIVISION_NAME}) I get error message "A string array is required here".
    Carl:
    I'm playing with cross-tab and I can use it to see all division_names in the report-header section. Since I need them in only one column or only one row, I have to edit cross-tab object and turn all unneeded border lines to white to make them look invisible. So, cross-tab could be a solution for my problem here.
    Another option could be to re-write my SQL command. Since I've read here that SQL command could be written in the same way as I would write a stored procedure, then I could use a bit more complex code to get all multiple division names from the database table into a local cursor, and then use do-while loop to concatenate them into one string, and then to return that string as one record (like 'DivA, DivB, DivC'), and then it should not be a problem to display only that one record/string in report header. It is my understanding that Crystal Reports can call stored procedure that works with many cursors/recordsets and CR will use only the last recordset from the stored procedure. Do you think it could be done this way?
    Thank you,
    Milan

  • Invoking a web service returning a arraylist of custom type

    Hi, I created a web service return a arraylist<InsertionSerialisable>.
    InsertionSerialisable can't be simpler here it is:
    public class InsertionSerialisable {
    public String nom = null;
    public String poids = null;
    I'm trying to use this arraylist in bpel but the returned parameter of my parter link for this web service is item of type anyType and I can't access my nom and poids string member. In a bpel process how can access member of custom element into an arraylist<InsertionSerialisable>?
    Here is my wsdl:
    <definitions
    name="ObtenirInsertions"
    targetNamespace="http://expedierdocument/"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:tns="http://expedierdocument/"
    xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
    xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
    xmlns:tns0="http://www.oracle.com/webservices/internal/literal"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    >
    <types>
    <schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://expedierdocument/"
    elementFormDefault="qualified" xmlns:tns="http://expedierdocument/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:ns1="http://www.oracle.com/webservices/internal/literal">
    <import namespace="http://www.oracle.com/webservices/internal/literal"/>
    <complexType name="InsertionSerialisable">
    <sequence>
    <element name="poids" type="string" nillable="true"/>
    <element name="nom" type="string" nillable="true"/>
    </sequence>
    </complexType>
    <element name="obtenirInsertions" type="tns:obtenirInsertions"/>
    <complexType name="obtenirInsertions">
    <sequence>
    <element name="inExpInsPath" type="string" nillable="true"/>
    <element name="inIdentificationLettre" type="string" nillable="true"/>
    <element name="inSpecialite" type="string" nillable="true"/>
    </sequence>
    </complexType>
    <element name="obtenirInsertionsResponse" type="tns:obtenirInsertionsResponse"/>
    <complexType name="obtenirInsertionsResponse">
    <sequence>
    <element name="return" type="ns1:arrayList" nillable="true"/>
    </sequence>
    </complexType>
    </schema>
    <schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.oracle.com/webservices/internal/literal"
    elementFormDefault="qualified" xmlns:tns="http://www.oracle.com/webservices/internal/literal"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/">
    <import namespace="http://expedierdocument/"/>
    <complexType name="arrayList">
    <complexContent>
    <extension base="tns:list">
    <sequence/>
    </extension>
    </complexContent>
    </complexType>
    <complexType name="list">
    <complexContent>
    <extension base="tns:collection">
    <sequence/>
    </extension>
    </complexContent>
    </complexType>
    <complexType name="collection">
    <sequence>
    <element name="item" type="anyType" minOccurs="0" maxOccurs="unbounded"/>
    </sequence>
    </complexType>
    </schema>
    </types>
    <message name="ObtenirInsertions_obtenirInsertions">
    <part name="parameters" element="tns:obtenirInsertions"/>
    </message>
    <message name="ObtenirInsertions_obtenirInsertionsResponse">
    <part name="parameters" element="tns:obtenirInsertionsResponse"/>
    </message>
    <portType name="ObtenirInsertions">
    <operation name="obtenirInsertions">
    <input message="tns:ObtenirInsertions_obtenirInsertions"/>
    <output message="tns:ObtenirInsertions_obtenirInsertionsResponse"/>
    </operation>
    </portType>
    <binding name="ObtenirInsertionsSoapHttp" type="tns:ObtenirInsertions">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="obtenirInsertions">
    <soap:operation soapAction=""/>
    <input>
    <soap:body use="literal"/>
    </input>
    <output>
    <soap:body use="literal"/>
    </output>
    </operation>
    </binding>
    <service name="ObtenirInsertions">
    <port name="ObtenirInsertionsSoapHttpPort" binding="tns:ObtenirInsertionsSoapHttp">
    <soap:address location="http://192.168.0.2:8888/Application1-ExpedierDocument-context-root/ObtenirInsertionsSoapHttpPort"/>
    </port>
    </service>
    </definitions>
    Thank you!

    Hi, I created a web service return a arraylist<InsertionSerialisable>.
    InsertionSerialisable can't be simpler here it is:
    public class InsertionSerialisable {
    public String nom = null;
    public String poids = null;
    I'm trying to use this arraylist in bpel but the returned parameter of my parter link for this web service is item of type anyType and I can't access my nom and poids string member. In a bpel process how can access member of custom element into an arraylist<InsertionSerialisable>?
    Here is my wsdl:
    <definitions
    name="ObtenirInsertions"
    targetNamespace="http://expedierdocument/"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:tns="http://expedierdocument/"
    xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
    xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
    xmlns:tns0="http://www.oracle.com/webservices/internal/literal"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    >
    <types>
    <schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://expedierdocument/"
    elementFormDefault="qualified" xmlns:tns="http://expedierdocument/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:ns1="http://www.oracle.com/webservices/internal/literal">
    <import namespace="http://www.oracle.com/webservices/internal/literal"/>
    <complexType name="InsertionSerialisable">
    <sequence>
    <element name="poids" type="string" nillable="true"/>
    <element name="nom" type="string" nillable="true"/>
    </sequence>
    </complexType>
    <element name="obtenirInsertions" type="tns:obtenirInsertions"/>
    <complexType name="obtenirInsertions">
    <sequence>
    <element name="inExpInsPath" type="string" nillable="true"/>
    <element name="inIdentificationLettre" type="string" nillable="true"/>
    <element name="inSpecialite" type="string" nillable="true"/>
    </sequence>
    </complexType>
    <element name="obtenirInsertionsResponse" type="tns:obtenirInsertionsResponse"/>
    <complexType name="obtenirInsertionsResponse">
    <sequence>
    <element name="return" type="ns1:arrayList" nillable="true"/>
    </sequence>
    </complexType>
    </schema>
    <schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.oracle.com/webservices/internal/literal"
    elementFormDefault="qualified" xmlns:tns="http://www.oracle.com/webservices/internal/literal"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/">
    <import namespace="http://expedierdocument/"/>
    <complexType name="arrayList">
    <complexContent>
    <extension base="tns:list">
    <sequence/>
    </extension>
    </complexContent>
    </complexType>
    <complexType name="list">
    <complexContent>
    <extension base="tns:collection">
    <sequence/>
    </extension>
    </complexContent>
    </complexType>
    <complexType name="collection">
    <sequence>
    <element name="item" type="anyType" minOccurs="0" maxOccurs="unbounded"/>
    </sequence>
    </complexType>
    </schema>
    </types>
    <message name="ObtenirInsertions_obtenirInsertions">
    <part name="parameters" element="tns:obtenirInsertions"/>
    </message>
    <message name="ObtenirInsertions_obtenirInsertionsResponse">
    <part name="parameters" element="tns:obtenirInsertionsResponse"/>
    </message>
    <portType name="ObtenirInsertions">
    <operation name="obtenirInsertions">
    <input message="tns:ObtenirInsertions_obtenirInsertions"/>
    <output message="tns:ObtenirInsertions_obtenirInsertionsResponse"/>
    </operation>
    </portType>
    <binding name="ObtenirInsertionsSoapHttp" type="tns:ObtenirInsertions">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="obtenirInsertions">
    <soap:operation soapAction=""/>
    <input>
    <soap:body use="literal"/>
    </input>
    <output>
    <soap:body use="literal"/>
    </output>
    </operation>
    </binding>
    <service name="ObtenirInsertions">
    <port name="ObtenirInsertionsSoapHttpPort" binding="tns:ObtenirInsertionsSoapHttp">
    <soap:address location="http://192.168.0.2:8888/Application1-ExpedierDocument-context-root/ObtenirInsertionsSoapHttpPort"/>
    </port>
    </service>
    </definitions>
    Thank you!

  • 9.0.3 plsql web service bug?

    I've been building plsql web services for several days, and everything has been fine. I've been adding new functions on the database side, and editing my web services using the JDev wizard.
    Now it's all stopped working, and I'm getting an "unexpected error" every time I try to generate the service. The "details" for the error looks like the stuff at the end of this message.
    Before this happened, I did two potentially problematic things. I was (I thought) done with my testing, so I was cleaning up. So, I removed some functions on the plsql side. And I also did "remove from IDE" for my existing web service project, so I could start building a clean version that had just what I needed. It was when creating the fresh web service in the new project that things exploded.
    As far as I can tell from the IDE, it generates the various serialization/deserialization files and the main web service class but fails before it can create the WSDL, web.xml, and deployment stuff.
    -- jim
    java.io.FileNotFoundException: /C:/Data/jdev9i/NEIEN1/Project1/src/__temp_java_wrappers/factlocal/Pk_web_service_test1.java (The system cannot find the file specified.
         void java.io.FileInputStream.open(java.lang.String)
              native code
         void java.io.FileInputStream.<init>(java.lang.String)
              FileInputStream.java:64
         java.io.InputStream oracle.ide.net.FileURLFileSystemHelper.openInputStream.java.net.URL)
              FileURLFileSystemHelper.java:415
         java.io.InputStream oracle.ide.net.URLFileSystem.openInputStream(java.net.URL)
              URLFileSystem.java:955
         void oracle.jdevimpl.webservices.generator.WrapperClassGenerator$1.run()
              WrapperClassGenerator.java:315
         void oracle.jdevimpl.webservices.util.ThreadUtil$NonThrowingRunnable.run()
              ThreadUtil.java:106
         void java.awt.event.InvocationEvent.dispatch()
              InvocationEvent.java:147
         void java.awt.EventQueue.dispatchEvent(java.awt.AWTEvent)
              EventQueue.java:337
         boolean java.awt.EventDispatchThread.pumpOneEventForHierarchy(java.awt.Component)
              EventDispatchThread.java:131
         void java.awt.EventDispatchThread.pumpEventsForHierarchy(java.awt.Conditional, java.awt.Component)
              EventDispatchThread.java:98
         void java.awt.Dialog.show()
              Dialog.java:380
         void java.awt.Component.show(boolean)
              Component.java:946
         void java.awt.Component.setVisible(boolean)
              Component.java:903
         boolean oracle.bali.ewt.dialog.JEWTDialog.runDialog()
         void oracle.ide.dialogs.ProgressBar.start(java.lang.String, java.lang.String)
              ProgressBar.java:274
         void oracle.jdevimpl.webservices.generator.SPWebServiceGenerator.generate(oracle.jdevimpl.webservices.wizard.publish.SPPublishModel, oracle.jdevimpl.webservices.util.JavaXSDTypeMap)
              SPWebServiceGenerator.java:187
         void oracle.jdevimpl.webservices.wizard.SPWebServicePublishWizard.wizardFinished(oracle.bali.ewt.wizard.WizardEvent)
              SPWebServicePublishWizard.java:391
         void oracle.bali.ewt.wizard.BaseWizard.processWizardEvent(oracle.bali.ewt.wizard.WizardEvent)
         void oracle.bali.ewt.wizard.BaseWizard.processEventImpl(java.awt.AWTEvent)
         void oracle.bali.ewt.LWComponent.processEvent(java.awt.AWTEvent)
         void oracle.bali.ewt.wizard.BaseWizard.doFinish()
         void oracle.bali.ewt.wizard.BaseWizard$Action.actionPerformed(java.awt.event.ActionEvent)
         void javax.swing.AbstractButton.fireActionPerformed(java.awt.event.ActionEvent)
              AbstractButton.java:1450
         void javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(java.awt.event.ActionEvent)
              AbstractButton.java:1504
         void javax.swing.DefaultButtonModel.fireActionPerformed(java.awt.event.ActionEvent)
              DefaultButtonModel.java:378
         void javax.swing.DefaultButtonModel.setPressed(boolean)
              DefaultButtonModel.java:250
         void javax.swing.plaf.basic.BasicButtonListener.mouseReleased(java.awt.event.MouseEvent)
              BasicButtonListener.java:216
         void java.awt.Component.processMouseEvent(java.awt.event.MouseEvent)
              Component.java:3715
         void java.awt.Component.processEvent(java.awt.AWTEvent)
              Component.java:3544
         void java.awt.Container.processEvent(java.awt.AWTEvent)
              Container.java:1164
         void java.awt.Component.dispatchEventImpl(java.awt.AWTEvent)
              Component.java:2593
         void java.awt.Container.dispatchEventImpl(java.awt.AWTEvent)
              Container.java:1213
         void java.awt.Component.dispatchEvent(java.awt.AWTEvent)
              Component.java:2497
         void java.awt.LightweightDispatcher.retargetMouseEvent(java.awt.Component, int, java.awt.event.MouseEvent)
              Container.java:2451
         boolean java.awt.LightweightDispatcher.processMouseEvent(java.awt.event.MouseEvent)
              Container.java:2216
         boolean java.awt.LightweightDispatcher.dispatchEvent(java.awt.AWTEvent)
              Container.java:2125
         void java.awt.Container.dispatchEventImpl(java.awt.AWTEvent)
              Container.java:1200
         void java.awt.Window.dispatchEventImpl(java.awt.AWTEvent)
              Window.java:922
         void java.awt.Component.dispatchEvent(java.awt.AWTEvent)
              Component.java:2497
         void java.awt.EventQueue.dispatchEvent(java.awt.AWTEvent)
              EventQueue.java:339
         boolean java.awt.EventDispatchThread.pumpOneEventForHierarchy(java.awt.Component)
              EventDispatchThread.java:131
         void java.awt.EventDispatchThread.pumpEventsForHierarchy(java.awt.Conditional, java.awt.Component)
              EventDispatchThread.java:98
         void java.awt.Dialog.show()
              Dialog.java:380
         void java.awt.Component.show(boolean)
              Component.java:946
         void java.awt.Component.setVisible(boolean)
              Component.java:903
         boolean oracle.bali.ewt.wizard.WizardDialog.runDialog()
         boolean oracle.ide.wizard.TitledWizardDialog.runDialog()
              TitledWizardDialog.java:147
         boolean oracle.jdevimpl.webservices.wizard.SPWebServicePublishWizard.runWizard()
              SPWebServicePublishWizard.java:404
         boolean oracle.jdevimpl.webservices.wizard.SPWebServicePublish.invoke(oracle.ide.addin.Context, java.lang.String[])
              SPWebServicePublish.java:221
         void oracle.ide.WizardManager$1.run()
              WizardManager.java:450
         void java.awt.event.InvocationEvent.dispatch()
              InvocationEvent.java:154
         void java.awt.EventQueue.dispatchEvent(java.awt.AWTEvent)
              EventQueue.java:337
         boolean java.awt.EventDispatchThread.pumpOneEventForHierarchy(java.awt.Component)
              EventDispatchThread.java:131
         void java.awt.EventDispatchThread.pumpEventsForHierarchy(java.awt.Conditional, java.awt.Component)
              EventDispatchThread.java:98
         void java.awt.EventDispatchThread.pumpEvents(java.awt.Conditional)
              EventDispatchThread.java:93
         void java.awt.EventDispatchThread.run()
              EventDispatchThread.java:85

    Could be. Here's what the console has on it. Of course, contrary to the message, it is an Oracle database. Good luck!
    Invoking JPublisher with command line:
    -user=w19572/w19572
    -driver=oracle.jdbc.driver.OracleDriver
    -url=jdbc:oracle:thin:@localhost:1521:HUDSOJ
    -numbertypes=objectjdbc
    -lobtypes=jdbc
    -usertypes=oracle
    -builtintypes=jdbc
    -case=mixed
    -encoding=Cp1252
    -methods=named
    -plsqlmap=true
    -transitive=true
    -omit_schema_names
    -dir=C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers
    -package=factlocal
    -input=C:\TEMP\input59112.jpub
    C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
    _test2.sqlj:43.5-44.17: Warning: You are using an Oracle JDBC driver, but connec
    ting to an non-Oracle database. SQLJ will perform JDBC-generic SQL checking.
    C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
    test2.sqlj:43.5-44.17: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_NAME. Ther
    e is no stored procedure or function of this name.
    C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
    test2.sqlj:53.5-54.17: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_SIC. There
    is no stored procedure or function of this name.
    C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
    test2.sqlj:63.5-64.17: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_SICLIST. T
    here is no stored procedure or function of this name.
    C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
    test2.sqlj:73.5-74.17: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_SIC_TABLE.
    There is no stored procedure or function of this name.
    C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
    test2.sqlj:83.5-84.15: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_WHEREDATA.
    There is no stored procedure or function of this name.
    C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
    test2.sqlj:94.5-96.21: Error: Not found: PKWEB_SERVICE_TEST2.UPDATE_NAME. Ther
    e is no stored procedure or function of this name.
    Total 6 errors and 1 warning.

  • Stored procedure returning multiple records without using SYS_REFCURSOR

    Hello,
    I am new to oracle stored procedures, have done stored procs in SQL server in past. I am trying to write single stored proc which will return multiple records. I have the stored proc as below and that is compiled without any errors.
    We don't want to use SYS_REFCURSOR as output param b'coz the place from which this proc is gonna call, that system doesn't support SYS_REFCURSOR param.
    create or replace
    PROCEDURE p_get5500DATA_MB (
    IN_plan_ID IN T_5500DATA_QWP.Plan_ID%TYPE,
    IN_plan_ID_col OUT T_5500DATA_QWP.Plan_ID%TYPE,
    p_SEQNUM OUT T_5500DATA_QWP.SEQNUM%TYPE,
    p_HEADER_CD OUT T_5500DATA_QWP.HEADER_CD%TYPE,
    p_VALUE1 OUT T_5500DATA_QWP.VALUE1%TYPE,
    p_VALUE2 OUT T_5500DATA_QWP.VALUE2%TYPE
    ) AS
    BEGIN
    SELECT
    Plan_ID,
    SEQNUM,
    HEADER_CD,
    VALUE1,
    VALUE2
    INTO
    IN_plan_ID_col,
    p_SEQNUM,
    p_HEADER_CD,
    p_VALUE1,
    p_VALUE2
    FROM TRS1DBO.T_5500DATA_QWP
    WHERE Plan_ID = IN_plan_ID
    ORDER BY SeqNum;
    -- EXCEPTION
    -- WHEN OTHERS THEN
    -- RAISE_APPLICATION_ERROR(-210001, 'Error in fetching data from T_5500DATA_QWP....');
    END;
    Error:
    ORA-01422: exact fetch returns more than requested number of rows
    ORA-06512: at "TRS1DBO.P_GET5500DATA_MB", line 10
    ORA-06512: at line 11
    My questions is:
    - What would be the best practice for this type of simple stored procedures?
    - Is there any alternate or is there anything i can fix in above stored proc which return multiple records?
    Thank you,
    Vimal

    Just out of curiosity, what are you using for API or driver that doesn't support a ref cursor? Ref cursors are pretty much the defacto standard for passing multiple records out of an Oracle procedure. Oracle's ODP.NET, OLEDB, ODBC, JDBC, OCI, all support ref cursors. Chances are that if the driver you're using doesn't support something as basic/fundamental as a ref cursor, it's probably also not going to support something else either.
    You'll most likely want to check with the driver/api vendor on their recommended approach.

  • Web Service returning JCO.Table with no content

    Hello all,
    I've written a web service returning an object of type JCO.Table
    When I'm testing it in the Web Service Navigator the response contains two parameters: tabLength and row (current row number), but doesn't contain the content of the table.
    I tried testing the Web Service also from Webdynpro but its the same -
    the result contains a ComplexTypeJCOTable and from that object I can only get the tabLength and row.
    Anyone knows why is it happening?
    Thanks for your help, Adi.

    Hi Rajendrakumar Gaikwad,
    Thanks for your suggestion.
    I don't think this will be an efficient solution for me or for the web service clients.
    I'm still looking for an explanation why can't I get the JCO.Table content.
    Is it impossible for some reason or am I doing anything wrong?
    Thanks again, Adi.

  • Develop PLSQL web services using JDeveloper.

    Dear Sir,
    1. Must we use OC4J to generate PLSQL webservices? or we can use any other J2EE compliant app server?
    2. Does it mean in Oracle environment, we can only use JAVA and not other language to wrap PLSQL stored procedures to create PLSQL web services?
    Please advise.
    Thank you.

    You don't need OC4J - you can use JDeveloper to generate Web services from PL/SQL
    You can manuall wrap PL/SQL into web services with any language - however JDeveloper uses Java to do this without the need for you to code anything.

Maybe you are looking for

  • Unable to delete applications from my i-pad 2

    I have delete some applications on the ipad from the  computer, but they are still on the ipad and i am unable to delete them from the ipad itself !! ? any help please ???

  • Double-click to create method/attribute in EHP2 Netweaver 7.0 does not work

    Hi, this makes me wonder: I'm used to create new attributes or methods by simply double-clicking the new name and the system will ask me to create. Now I am new in EHP2 and for methods it just says 'wrong cursor position or object not in navigation',

  • Get the report name in reports 6i??

    Hi!! I need to get the report name from reports 6i, in forms i can get the form name whit :SYSTEM.CURRENT_FORM, but in reports this is not possible. How Can I get the name of the report?? Thanks! Regards!! Edited by: JuaNiNNaio on 30-jun-2009 9:55

  • Going dump for ME41 t-code

    Hi Friends, I activated MM06E005 using  SMOD t-code. if run ME41 system going dump and it is saying Program "SAPLXM06" tried to use screen 0301. The screen does not exist. Can any body help what may be the wrong. It is working fine for ME21, Me51. I

  • Call .js file through VB[Error]

    Hello, Using Visual Basic, i called the .js file. Its works most of the time. Some times, its throws an runtime error. Could you please advice me, how to solve this. Regards, Maria