DBMS_SQL.BIND_VARIABLE with nested table and ORA-600

Hello, I'm experimenting a little with pl/sql and I was trying to do some dynamic SQL using DBMS_SQL, but I'm having a problem when binding a variable that is a neste table(got no problems in the same example if I bind with a varchar2 variable).
Here is a reduction of the problem:
DECLARE
     TYPE CENA_TYPE IS TABLE OF VARCHAR2(30);
     CENA CENA_TYPE;
     L_UPDATE_STMT VARCHAR2(2000);
     UPDATE_CURSOR INTEGER:=DBMS_SQL.OPEN_CURSOR;
     RES INTEGER;
BEGIN
     CENA:=CENA_TYPE('HELLO');
     L_UPDATE_STMT:= 'BEGIN '
                         ||'DBMS_OUTPUT.PUT_LINE(:CENA(1));'
                         ||'END;';
     DBMS_SQL.PARSE(UPDATE_CURSOR, L_UPDATE_STMT ,DBMS_SQL.NATIVE);
     DBMS_SQL.BIND_VARIABLE(UPDATE_CURSOR,':CENA',CENA);
     RES:=DBMS_SQL.EXECUTE(UPDATE_CURSOR);
     DBMS_SQL.CLOSE_CURSOR(UPDATE_CURSOR);
END;
/What am I doing wrong??
Thanks

Pedro_gloria wrote:
What am I doing wrong??DBMS_SQL executes in own context. Therefore, even though type CENA_TYPE is declared in calling anonymous block it is not known to anonymous block you execute in DBMS_SQL. Also, you must initialize and extend collection. Use:
SQL> set serveroutput on
SQL> DECLARE
  2   L_UPDATE_STMT VARCHAR2(2000);
  3   UPDATE_CURSOR INTEGER:=DBMS_SQL.OPEN_CURSOR;
  4   RES INTEGER;
  5  BEGIN
  6   L_UPDATE_STMT:= 'DECLARE
  7   TYPE CENA_TYPE IS TABLE OF VARCHAR2(30);
  8   CENA CENA_TYPE := CENA_TYPE();
  9          BEGIN '
10       ||'CENA.extend;'
11       ||'CENA(1) := :1;'
12       ||'DBMS_OUTPUT.PUT_LINE(CENA(1));'
13       ||'END;';
14   DBMS_SQL.PARSE(UPDATE_CURSOR, L_UPDATE_STMT ,DBMS_SQL.NATIVE);
15   DBMS_SQL.BIND_VARIABLE(UPDATE_CURSOR,':1','Hello');
16   RES:=DBMS_SQL.EXECUTE(UPDATE_CURSOR);
17   DBMS_SQL.CLOSE_CURSOR(UPDATE_CURSOR);
18  END;
19  /
Hello
PL/SQL procedure successfully completed.
SQL> SY.

Similar Messages

  • Issues with Nested Tables and Adobe Designer

    Hi,
    I have some strange issues when I am trying to create a nested dynamic table with SAP DATA in Adobe Designer.
    My Outer Table has article items and in this table I got a nested charges. For instance the table contains this data:
    DATA
    |->Article1
    |--->charge111
    |--->charge211
    |
    |->Article2
    |--->charge122
    |--->charge222
    Now I am trying to display the data in a Adobe Designer table. But if I create a table with a row article and a repeating row charge all charges will be displayed under the first Article.
    This is the result:
    DATA
    |->Article1
    |--->charge111
    |--->charge211
    |--->charge122
    |--->charge222
    |
    |->Article2
    How can I solve this issue? I tried to select data binding on charges like article.DATA.charges.DATA[*] but this don't work.
    Anyone an idea?

    Alex,
    Is it print based form or interactvie form.
    ABAP
    If it is printbased form and if you are designing from SFP, you can use the following solution.
    You have to create a nested table in the context as below.
    say Table1-> Article ( fields: ARTICLENAME,....other fields) info Table2->cost info(fields:ARTICLENAME,Charge...,other fields).
    The 2 tables should contains data as beow.
    Table1 data.
    1row->Article1  -.....other values.
    2row->Article2  -.....other values.
    3row->Article3  -.....other values.
    Table2 data.
    1row->Article1  -Charge11 .....other values.
    2row->Article1  -Charge12 .....other values.
    3row->Article1  -Charge13 .....other values.
    4row->Article2  -Charge21 .....other values.
    5row->Article2  -Charge22 .....other values.
    6row->Article2  -Charge23 .....other values.
    7row->Article3  -Charge31 .....other values.
    8row->Article3  -Charge32 .....other values.
    9row->Article3  -Charge33 .....other values.
    In the context drag table2 into the table1 and define where clause on ARTICLENAME.
    In the layout drag nested table in the body page and make alignments.
    If your requirement is interactive, may be you can use the similar logic.

  • Object view  with nested table and member functions????????????????

    HI frds:)
    I need some help regarding writeing soem queries..
    I have to use view in retreving data and by useing member functions of object.
    1) i have to create a nested table by useing type object.
    2) i have to create a object wtih member functions inorder to create view of taht nested table,.
    3) by useing this objectt view and by useing methods i have to write soem queries ...
    If any one know or any information regarding this please reply me... as i have searched in net alot but i was unable to figure out..
    Thanks....

    // first createing object
    create type emp_det as object
    (empname varcahr2(20),start_date date,end_date date);
    // creating table of that object
    create table emp_detai_table as table of emp_det;
    // creating nested table
    create table empl (emp_no number,emp_detail emp_detail_table,dep_no number)nested table emp_detail store as s;
    //now i want to create view.. inorder to create view i need to create object. in that object i want to create methods.. these methods should work with date attributes..
    after creating object view i need to select or write some queries by useing member methods..
    This is the tast i have to perform.,. i have no materials ...if u have any link ..forward me..
    i have to do it as soon as possible..
    waiting for your reply...

  • Import tables with nested table : ORA-00600

    In Oracle 9.2
    Create object, type as table, and table with nested table (store as syms_ntab) are successfully.
    Also its export.
    In process of import on another server (also 9.2, 'fromuser=one touser=two') shows errors:
    . . importing table "SYMS_NTAB"
    IMP-00058: ORACLE error 600 encountered
    ORA-00600: internal error code, arguments: [kokeeafi1], [2], [2], [], [], [], [], []
    IMP-00075: Warning: The nested table may contain partial rows or duplicate rows
    But for all that table is created and error occur on phase inserting strings.
    What is this?
    In Oracle 8.0.5 i perform similar operation without error.

    From Oracle error messages and codes manual:
    ORA-00600 internal error code, arguments: [string], [string], [string], [string], [string], [string], [string], [string]
    Cause: This is the generic internal error number for Oracle program exceptions. It indicates that a process has encountered a low-level, unexpected condition. Causes of this message include:
    * timeouts
    * file corruption
    * failed data checks in memory
    * hardware, memory, or I/O errors
    * incorrectly restored files
    The first argument is the internal message number. Other arguments are various numbers, names, and character strings. The numbers may change meanings between different versions of Oracle.
    Action: Report this error to Oracle Support Services after gathering the following information:
    * events that led up to the error
    * the operations that were attempted that led to the error
    * the conditions of the operating system and databases at the time of the error
    * any unusual circumstances that occurred before receiving the ORA-00600 message
    * contents of any trace files generated by the error
    * the relevant portions of the Alter files
    Note: The cause of this message may manifest itself as different errors at different times. Be aware of the history of errors that occurred before this internal error.

  • CAST and MULTISET with nested table

    I am trying to figure out the syntax of using
    MULTISET. I have two queries.
    One very basic where I want to cast the station names
    and ids, retrieved from a regular table into a nested
    table.
    e.g.
    SELECT cast(multiset(stn_id, stn_name) as castTab) FROM station_tab WHERE stn_name like '%xyz%';
    The other retrieve sections of a nested table and cast back as
    nested table type.
    SELECT * FROM CAST(MULTISET(SELECT * FROM
    THE (SELECT tmn_history FROM tmin WHERE tmn_stn_ncdcid = 01063456) NT
    WHERE (EXTRACT(YEAR FROM NT.dta_date) = 1915) AS data_tab ;
    The schema/tables are as follows
    =========================================================================
    CREATE TABLE station_tab
         stn_id     INTEGER PRIMARY KEY,
         stn_name VARCHAR(50)
    CREATE OR REPLACE TYPE data_point AS OBJECT
         dta_date      DATE,
         dta_val NUMBER,
         dta_dtobtnd DATE
    CREATE OR REPLACE TYPE data_tab AS TABLE OF data_point;
    CREATE TABLE tmin
    tmn_stn_id     INTEGER ,
    tmn_history data_tab
    ) NESTED TABLE tmn_history STORE AS tmn_history_tab;
    CREATE OR REPLACE TYPE castObj AS OBJECT
         dta_val NUMBER,
         stn_name VARCHAR(50)
    CREATE OR REPLACE TYPE castTab AS TABLE OF castObj;
    =====================================================================
    Thank you.
    barr

    With trial and error and going thru the examples
    in AskTom and documentation found that the follwing syntax works.
    (Also realized this is the wrong forum);
    SELECT * FROM TABLE (cast(multiset
    (SELECT stn_ncdcid,stn_name FROM station_tab WHERE stn_name LIKE '%WSFO%')
    AS castTab));
    select * FROM TABLE (CAST(MULTISET (SELECT * FROM
    THE (SELECT tmn_history FROM tmin WHERE tmn_stn_ncdcid = 01063456) NT
    WHERE (EXTRACT(YEAR FROM NT.dta_date) = 1915)
    ORDER BY NT.dta_date) as data_tab)) ;

  • Nested Tables and Advanced Queues- Please Help.

    How do i work with NestedTable type and Advanced Queue.
    I have done the following
    I have Oracle 8.1.7 enterprise edition.
    create type myType as TABLE OF varchar(32);
    create type myObject as OBJECT (
    id int,
    myt myType);
    DECLARE
    BEGIN
    dbms_aqadm.create_queue_table(
    queue_table => 'my_queue_table',
    multiple_consumers => TRUE,
    queue_payload_type => 'myObject',
    compatible => '8.1.3'
    END;
    The Nested Table and Object are created successfully.
    but the queue is not created.
    I get the following message.
    DECLARE
    ERROR at line 1:
    ORA-22913: must specify table name for nested table column or
    attribute
    ORA-06512: at "SYS.DBMS_AQADM_SYS", line 2012
    ORA-06512: at "SYS.DBMS_AQADM", line 55
    ORA-06512: at line 3
    I know how to specify the nested table storage clause for
    create table statement, but there is no provision for
    it in the create_queue_table procedure.
    Any help will be greately appriciated.
    i have already created and tested aqs with simple data types,
    also i have created simple tables with nested table type
    elements.
    but the combo of Nested tables and AQ is not working.
    thanks in advance.

    Hi Francois. Thank you very much for your reply, but it seems that i still get errors. So let me tell what i have done.
    As you suggested me: i have done a block based on a sub-query for the nested-table:
    'select courses from department where name= :department.name'.
    In the master block(department) i have the when-new-record-instance trigger:
    Declare
    LC$Req varchar2(256);
    Begin
    LC$Req := '(select ns.courses from table
    ( select courses from department where name = ''' || :DEPARTMENT.name || ''' ) ns )';
    Go_block('block11');
    Clear_Block ;
    Set_Block_Property( 'block11', QUERY_DATA_SOURCE_NAME, LC$Req ) ;
    Execute_query ;
    End ;
    Now the errors i receive, this time in the runtime mode are:
    - FRM-41380: Cannot set the blocks query data source
    -FRM-41003: This function cannot be performed here.
    Since it seems that you know how to work with the nested table i would really appreaciate your help. I am new in the nested table and if you could give an ex with my tables it would be great.
    Thank you in advance.

  • Nested Tables and Multiple Pages

    Hi,
    I have a problem with nested tables that span multiple pages.
    Lets assume I want to create a list of orders. Each order contains several order items. As long as an order contains less order items than fit to one page the list is rendered correctly. But if an order contain more items all items that can´t be displayed at the first page are cut off.
    I´ve tried so many combinations of subforms with flow content and position content, subform sets and "Allow Page Breaks within Content" as well as Layout Property "Expand to fit" but nothing helped.
    Can someone tell me if and how I can achieve this. In the meantime I do work in Designer directly with a XML datasource. So I could send you the form and example data.
    I´m working with NW04 SP11 and Adobe Designer 6.0
    Best regards
    Helmut

    Hello Helmut,
    There are some limitations and bugs in your requirement.
    Please see the output after copying into notepad.
    1.Eventhough if you give overflow leader , the headers for item table will not repeat.it is a bug.this is not solved in designer 7.1 also.
    2.There are some accessibilty bugs in case of nested table.
    Please follow the below design in the hierachy tab.
    MainTable (subform)
          |---- Header (subform)
          |      |- Header texts for Main table   +
          |      |-     Text for nested table
          |---- DATA_main (subform)     
                 |-Main table fields
              |-ITEMDATA ( Table SUBFORM)  
                     |-Header (Subform)
                     |   |-ItemHeader texts
                     |-DATA_item (subform)
                        |-Item data fields     
    for DATA_main and DATA_item subforms, set repeat count MIN in binding tab.Set all flow content and allow page break with in the content.
    The output will appear in the following manner.
    <b>( Copy the below text into the notepad. )</b>
    <b>Order no.     text                 customer
                    Order items</b>
    =================================================================
    1             Computer             Mr. Smith
       <b>Order item no.     short text          quantity        price</b>  
        10                 PC Tower            1               400.00
        20                 LCD Display         1               200.00
        30                 Keyboard            1                15.00
        40                 Mouse               1                10.00
    2             Notebook             Mrs. Parker
       <b>Order item no.     short text          quantity        price</b>  
        10                 HP Notebook         1               600.00
        20                 Ext. hard drive     1                80.00
    let me know if u didnt get the solution.
    Thanks and Regards,
    Pavan Meda

  • Partition exchange error on table with nested table

    On Oracle 11.2.0.1, I have a partitioned table with some partitions that need to be 'archived' (in terms of moving partitions to an 'archive' table).
    I have a source table like:
    CREATE TABLE IS_PODACI245
      ID_OBJEKTA_IDENTIFIKACIJA  NUMBER(10),
      ID_OBJEKTA                 NUMBER(20),
      DATUM                      TIMESTAMP(6)       NOT NULL,
      TZ                         NUMBER(3),
      DATA1                      NUMBER(10),
      DATA2                      NUMBER(6),
      DATA3                      NUMBER(10),
      DATA4                      NUMBER,
      DATA5                      T_NTCIP_CLIMATE_TABLE
    NESTED TABLE DATA5 STORE AS IS_PODACI245_STORE_TABLE
    TABLESPACE DATA
    PARTITION BY RANGE (DATUM)
      PARTITION P_201107 VALUES LESS THAN (TIMESTAMP' 2011-08-01 00:00:00')
        LOGGING
        NOCOMPRESS
        TABLESPACE DATA, 
      PARTITION P_MAXVALUE VALUES LESS THAN (MAXVALUE)
        LOGGING
        NOCOMPRESS
        TABLESPACE DATA
    NOCOMPRESS
    NOCACHE
    NOPARALLEL
    MONITORING;
    CREATE INDEX IDX_IS_PODACI245_KOMPLEKS ON IS_PODACI245
    (ID_OBJEKTA_IDENTIFIKACIJA, ID_OBJEKTA, DATUM)
      TABLESPACE DATA
    LOCAL ( 
      PARTITION P_201107
        LOGGING
        NOCOMPRESS
        TABLESPACE DATA, 
      PARTITION P_MAXVALUE
        LOGGING
        NOCOMPRESS
        TABLESPACE DATA
    NOPARALLEL;
    CREATE OR REPLACE TYPE t_ntcip_climate_table as table of t_ntcip_climate_fmt;
    CREATE OR REPLACE TYPE t_ntcip_climate_FMT as object
    (  dev_index number(6)
    ,   dev_description varchar2(512)
    ,   dev_type number(10)
    ,   dev_status number(10)
    ,   dev_mfr_status varchar2(512)
    ,   dev_active number(3)
    ,   dev_test_activation number(10)
    /I would like to make exchange partition using stage table, and everything is going fine on all tables, but only on a few of them (listed source is one of them, and they're only tables with nested tables wihin), where I get an error.. but sometimes ;)
    on a statement like:
    ALTER TABLE IS_PODACI245_ARH EXCHANGE PARTITION P_201106  WITH TABLE IS_PODACI245_STAGE EXCLUDING INDEXES  WITHOUT VALIDATION;I got an error:
    ORA-00001: unique constraint (TXV.SYS_C0032911) violated
    it's an unique index between parent and nested table.
    what could cause that problem?

    Dear,
    I suppose that the unique constraint
    ORA-00001: unique constraint (TXV.SYS_C0032911) violatedis the one you 've created on the nested table IS_PODACI245_STORE_TABLE
    If so, why not disable that constraint and try again.
    I have never exchanged such a kind of partitioned table having a nested table in it. But, I could imagine that the cloned non partitioned table IS_PODACI245_STAGE should at least be the exact image of the partitioned table IS_PODACI245_ARH (of course without the partition part) but with the nested table part and including all indexes
    In addition, if you have a parent/child relationship between your partitioned tables, then there is a chronological order of exchange starting by the child and then finishing by the parent
    see the following link for more information about this order of exchange (and comment 2 for an example also)
    http://jonathanlewis.wordpress.com/2006/12/10/drop-parent-partition/#more-65
    Hope this helps
    Mohamed Houri

  • Trying to UNION two views with nested tables

    I am using Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Prod, and my objective is to generate some XML. What I have been doing in the past, is to create a view, and then pass that view to the DBMS_XMLQuery routine. This gives me a CLOB that I pass along to the application. A typical object would be something like:
    create or replace type XML_UGroup_Member_Type as object (
         username          varchar2(128),
         group_key          varchar2(128));
    create or replace type XML_UGroup_Member_List
        as table of XML_UGroup_Member_Type;
    show errors
    Create or replace type XML_UGroup_Type as object (
         Group_Space     varchar2(32),
         group_key     varchar2(128),
         group_name     varchar2(255),
         members          XML_UGroup_Member_List);
    /This particular application will be doing stuff with group information. Pretty simply types - a group with a name and a few other keys, and a list of members. A sample view would be like:
    create or replace view xml_department_ugroup_view of xml_ugroup_type
      with object identifier ( group_key ) as
      Select 'Department',
          'Department:' || orgn_code,
          'Department_' || orgn_name
          cast ( multiset (
               select  Username, person_id,
                        'Department:' ||  effective_orgn
                from directory_master dm, logins l
               where effective_orgn = dd.orgn_code
                 and dm.person_id = l.owner)
                as XML_UGroup_Member_List )
             as members
       from directory_departments dd
      where dept_include = 'Y';
    can select from this view, and I can pass it to the DBMS_XMLQUERY package and get a nice XML document. What I want to is essentially put several of these views together, like
    Select * from XML_Department_Ugroup_View
    Union
    Select * from XML_Portfolio_Ugroup_View;But UNION does not work with nested tables:
    ERROR at line 1: ORA-00932: inconsistent datatypes: expected - got SIMON.XML_UGROUP_MEMBER_LIST
    What I was hoping to do, was to develop a set of sub views for each of the group "spaces", and then generate a view/object that includes all of the sub views, and be able to operate with that single object.
    Thoughts on how to make this work, or on alternate approaches? I have considered calling XMLQuery on each of the sub views and concatenating the XML documents and returning that to the application, but I was hoping to find a more "unified" approach.

    I modified my approach a bit - I changed the base views to return an XMLType object, like:
    create or replace view xml_portfolio_ugroup_xml
    as
    Select XMLElement("group",
             xml_ugroup_type(
          'Portfolio',
             'Portfolio:' || coas_code || ':' || orgn_Code,
          cast ( multiset (
               select  Username,
                from directory_master dm, logins l
               where ( effective_orgn, effective_coas ) in
               where effective_orgn = dd.orgn_code
                  and dm.person_id = l.owner
                as XML_UGroup_Member_List ))) as grp
       from directory_departments dd
      where dept_include = 'Y';and then I combined them with something like the following (I expect to adjust this as I learn more about the XML DB support)
    create or replace view xml_ugroup_xml as
      select xmlconcat(
         (select xmlagg(grp) from xml_department_ugroup_xml),
         (select xmlagg(grp) from xml_portfolio_ugroup_xml)
         ) as GROUPS
         from dualand as I define more group branches, I can add them into the XMLConCat stanzas. I am still open to suggestions as to ways of doing this better or cleaner, but this at least gets the project moving forward again.

  • Unable to export nested tables and vaarys

    Hai
    How to export nested tables and varrays in oracle 8i (8.1.6) .When exporting nested tables and varrays not exporting .What is the advantage use of nested tables and varrays
    Thanks in advance
    mohan

    Hello,
    I think that with such a new release you should use DataPump (expdp/impdb) to
    export Tables.
    For exporting a complete Schema you may use the following syntax:
    expdp {color:red}+user+{color}/{color:red}+password+{color} PARFILE=pfexport.txt_With pfexport.txt as bellow:_
    SCHEMAS={color:red}+schema_name+{color}
    FLASHBACK_TIME="TO_TIMESTAMP(to_char(SYSDATE,'DD-MM-YYYY HH24:MI:SS'),'DD-MM-YYYY HH24:MI:SS')"
    CONTENT=ALL
    DIRECTORY=EXP_DIR
    DUMPFILE={color:red}+dump_file_name+{color}
    LOGFILE={color:red}+log_file_name+{color}Then, in this example, you'll get the "dump file" and the "log file" into the EXP_DIR Oracle directory (if it exists).
    You can check your Oracle Directories with the following query:
    select * from dba_directories;Then, you can use one of these Directories or create a new one with the following statement
    CREATE OR REPLACE DIRECTORY {color:red}+directory_name+{color} AS '{color:red}+directory_path+{color}';
    GRANT READ,WRITE ON DIRECTORY {color:red}+directory_name+{color} TO {color:red}+user_name+{color};Hope it can help,
    Best regards,
    Jean-Valentin
    Edited by: Lubiez Jean-Valentin on Nov 28, 2009 12:08 PM

  • Full Export/Import Errors with Queue tables and ApEx

    I'm trying to take a full export of an existing database in order to build an identical copy in another database instance, but the import is failing each time and causing problems with queue tables and Apex tables.
    I have used both the export utility and Data Pump (both with partial and full exports) and the same problems are occurring.
    After import, queue tables in my schema are unstable. They cannot be dropped using the queue admin packages as they throw ORA-24002: QUEUE_TABLE <table> does not exist exceptions. Trying to drop the tables causes the ORA-24005: must use DBMS_AQADM.DROP_QUEUE_TABLE to drop queue tables error
    As a result, the schema cannot be dropped at all unless manual data dictionary clean up steps (as per metalink) are done.
    The Apex import fails when creating foreign keys to WWV_FLOW_FILE_OBJECTS$PART. It creates the table ok, but for some reason the characters after the $ are missing so the referencing tables try to refer to WWV_FLOW_FILE_OBJECTS$ only.
    I am exporting from Enterprise Edition 10.2.0.1 and importing into Standard edition 10.2.0.1, but we are not using any of the features not available in standard, and I doubt this would cause the issues I'm getting.
    Can anyone offer any advice on how I can resolve these problems so a full import will work reliably?

    Thanks for the lead!
    After digging around MetaLink some more, it sounds like I'm running into Bug 5875568 (MetaLink Note:5875568.8) which is in fact related to the multibyte character set. The bug is fixed in the server patch set 10.2.0.4 or release 11.1.0.6.

  • Nested Tables and Forms 9i-please help

    Hi
    i have the folowing example of a nested table:
    CREATE TYPE CourseList AS TABLE OF VARCHAR2(10) -- define TABLE type
    CREATE TYPE Student AS OBJECT ( -- create object
    id_num INTEGER(4),
    name VARCHAR2(25),
    address VARCHAR2(35),
    status CHAR(2),
    courses CourseList) -- declare nested table as attribute
    CREATE TYPE Course AS OBJECT (
    course_no NUMBER(4),
    title VARCHAR2(35),
    credits NUMBER(1));
    CREATE TYPE CourseList AS TABLE OF Course;
    CREATE TABLE department (name VARCHAR2(20),
    director VARCHAR2(20),
    office VARCHAR2(20),
    courses CourseList)
    NESTED TABLE courses STORE AS courses_tab;
    In Forms i have created a data block based on table department and for managing the nested table courses_tab i found out that i should use a stored procedure:
    PROCEDURE procedure_nest (c_c out courses_tab%rowtype) IS
    c_c courselist;
    BEGIN
    select c.name, c.director,office into :department.name, :department.director,
    :department.office from department c , table
    (select n.courses from department n where c.name =n.name and rownum<=1);
    END;
    compil error:
    error 999 at line 1, column 35
    implemntation restriction (may be temporary) ADT or schema level
    collection not supported at client side with non-OCI mode.
    i really would like to know what shall i do to use and manage the nested table in forms.
    Thank you very much

    Hi Francois. Thank you very much for your reply, but it seems that i still get errors. So let me tell what i have done.
    As you suggested me: i have done a block based on a sub-query for the nested-table:
    'select courses from department where name= :department.name'.
    In the master block(department) i have the when-new-record-instance trigger:
    Declare
    LC$Req varchar2(256);
    Begin
    LC$Req := '(select ns.courses from table
    ( select courses from department where name = ''' || :DEPARTMENT.name || ''' ) ns )';
    Go_block('block11');
    Clear_Block ;
    Set_Block_Property( 'block11', QUERY_DATA_SOURCE_NAME, LC$Req ) ;
    Execute_query ;
    End ;
    Now the errors i receive, this time in the runtime mode are:
    - FRM-41380: Cannot set the blocks query data source
    -FRM-41003: This function cannot be performed here.
    Since it seems that you know how to work with the nested table i would really appreaciate your help. I am new in the nested table and if you could give an ex with my tables it would be great.
    Thank you in advance.

  • Nested Tables and XSU

    Does anyone know if XSU supports the use of nested tables?
    I have looked at the examples in the documentation that show how to use XSU with an object-relational schema. They work great if you have a fairly simple schema, (no nested tables). The XML documents I am trying to get into my database are a bit more complex and contain collections of repeating elements. I have created a schema that includes nested tables to support these repeating elements. My problem is when I try to access the object table via XSU. As long as I don't reference the nested table columns all works fine. Am I trying to do something that is not supported by XSU?

    Steve,
    What release is your database server?
    XSU should work fine with nested tables. Did you check out samples in http://download-west.oracle.com/docs/cd/B10501_01/appdev.920/a96621/adx08xsu.htm#1014730?
    Regards,
    Geoff

  • PL/SQL add procedure with nested table - Duplicate Thread

    Hi,
    I am trying to do a procedure to input information for one order and another for 2 orders.
    The information I have so far is as follows:
    Drop table Orders cascade constraints;
    Drop type item_type;
    Drop type Item_nested;
    Create or Replace Type item_type AS Object (
    Cat_code Varchar2(6),
    Amount_ord Number(3),
    Cost Number(5,2) );
    Create or Replace Type item_nested as table of item_type;
    Create Table Orders (
    Order_no Varchar2(8) constraint pkorder primary key,
    Customer_name Varchar2(30),
    AddressLine1 Varchar2(20),
    AddressLine2 Varchar2(20),
    AddressLine3 Varchar2(20),
    Town Varchar2(20),
    Postcode Varchar2(10),
    Country Varchar2(20),
    Order_items item_nested,
    Order_date Date)
    Nested Table Order_items
    Store as nested_items return as locator;
    This has so far worked but I have not managed the insert procedure.
    I am using Oracle SQL*plus
    Thanks
    SG
    Edited by: user10689875 on 11-Jan-2009 03:39

    Duplicate thread ->
    PL/SQL add procedure with nested table
    Please remove it & marked it as duplicate.
    Regards.
    Satyaki De.

  • Problem when expanding Tree - Tree with nested table column

    Hi, i have created the tree using the Tree with nested table column.
    I have created a node called TREE_ROOT in the context.
    This node has few attributes which includes children_loaded, is_leaf, is_expanded.
    I have created the recursive node TREE_SUB for the above node TREE_ROOT.
    In the view, i have created the table with the master column. The above attributes have been mapped accordingly. I have created the action handler for load_children.
    In this action handler method, i receive the context_element correctly. In this method, i determine the children of the selected element and the resulting children are attached to this context_element.
    But the problem is: when i add elements to context_elements in the method load_children, these
    elements get added to the node TREE_ROOT as well.
    Please help.
    thanks and best regards,
    Pramod

    I just use some types defined in this user... Well, I hope you know what is the type definition of d_period_sec,
    don't you ? I didn't ask to provide all types existed now, only types you are
    using.
    Anyhow you have been granted with execute privilege for types you are using:
    SQL> conn tau_tll/tau_tll;
    Connected.
    SQL> create or replace type d_period_sec as object (date# date);
      2  /
    Type created.
    SQL> grant execute on d_period_sec to public with grant option;
    Grant succeeded.
    SQL> conn scott/tiger
    Connected.
    SQL> CREATE OR REPLACE TYPE unit_function AS OBJECT (
      2  xi NUMBER,
      3  yi NUMBER,
      4  xe NUMBER,
      5  ye NUMBER,
      6  xm NUMBER,
      7  ym NUMBER,
      8  v NUMBER,
      9  a NUMBER,
    10  f NUMBER,
    11  descr VARCHAR2 (20)
    12  );
    13  /
    Type created.
    SQL> grant execute on unit_function to master;
    Grant succeeded.
    SQL> CREATE OR REPLACE TYPE unit_moving_point AS OBJECT
      2  (
      3  p tau_tll.d_period_sec, -- from user TAU_TLL
      4 
      5  m unit_function
      6  )
      7  /
    Type created.
    SQL> grant execute on unit_moving_point to master;
    Grant succeeded.
    SQL> CREATE OR REPLACE TYPE moving_point_tab AS TABLE OF unit_moving_point;
      2  /
    Type created.
    SQL> grant execute on moving_point_tab to master;
    Grant succeeded.
    SQL> CREATE OR REPLACE TYPE moving_point AS OBJECT (u_tab moving_point_tab);
      2  /
    Type created.
    SQL> grant execute on moving_point to master;
    Grant succeeded.
    SQL> conn master/master
    Connected.
    SQL> CREATE TABLE MPOINTS (
      2  id NUMBER,
      3  mpoint scott.Moving_Point)
      4  NESTED TABLE mpoint.u_tab store as moving_tab;
    Table created.Rgds.

Maybe you are looking for

  • Where is the bookmarks.html file ?

    My customers PC crashed. I try to copy the Bookmarks to a new PC. I can not find the right bookmarks.html file, only the default and th bookmarkbackups directory with those *.json files. BTW: is there some intelligible reason, why the bookmark file o

  • Scroll with mouse wheel requires multiple "ticks" to start scrolling

    I recently got a new mouse, and now when using firefox the scroll wheel doesn't want to work correctly. Everywhere else I can do single scroll ticks to scroll content, but in firefox a single tick scroll is just ignored as are multiple ticks if done

  • Problem to make able Offline File Windows 7

    Hi, I need your help to solve this problem whit the offline files. This is the step-by-step of what i done: I opened the control panel in windows 7 I Clicked on the sync center icon I Clicked on the manage offline files link I Clicked on the enable o

  • Email not sending in Business One

    Hi Experts, I have a customer that is trying to email using B1 and the emails just sit in the outbox and don't send. They are not receiving an error and it is only on one user and one computer in the system. If the user that is trying to send the ema

  • Error in external tax system: Line: 0##### - Unknown tax calculation (MIRO)

    Hi Friends, We have an issue while doing the MIRO Scenario : - Company code in USD Currency, we have a purchase order in EUR currency which had GR and IR in EUR only last year..this year when we are trying to process IR ( MIRO) for residual amount in