LOV in richeTableau resets the value after the deletion of rows from the table

Hello. I'm on 11g R2

I have a table with columns in the box and a button in the toolbar that removes the lines checked

I have build it based on the following article in her string code

http://www.Oracle.com/technetwork/developer-tools/ADF/learnmore/index-101235.html


When I run the "delete" button I execute the following code (taken as is article)


public void deleteSelectedRows() {}

create a second line, the value do not affect all lines

used in ADF

Set of rows duplicateRowSet = this.createRowSet ("duplicateRowSet");

first row to avoid "the attempt to access the value of lines."

exception line was dead.

duplicateRowSet.first ();

retrieve the current row of the table for after

re-running the VO

Line currentRow = this.getCurrentRow ();

Boolean currentRowDeleted = false;

get all rows that have the transoent attribute

"MarkForDelete' set to true

Row [] rowsToDelete =

duplicateRowSet.getFilteredRows ("MarkedForDelete", true);

If (rowsToDelete.length > 0) {}

run only throizgh this code, if there is something to

delete

for (line rw: rowsToDelete) {}

If the row is marked as the current in VO, ts value

Boolean flag

If (rw.getKey () .equals (currentRow.getKey ())) {}

currentRowDeleted = true;

}

remove the line - do not yet commit

RW. Remove();

}

rerun VO

this.executeQuery ();

reset the current line if it has not been removed

If (! currentRowDeleted) {}

this.setCurrentRow (currentRow);

}

duplicateRowSet.closeRowSet ();

}

}

"MarkedForDelete" is a transient attribute used to mark the line delete

The lines are removed very well.

The problem is with lines that I do not delete.

For example I LOV column. I chose the value LOV in a few lines, and after that choose to delete several lines (not the same lines where I modified the LOV) but some other lines.

After I click "delete", the lines that I marked to remove deleted indeed, but the value of the LOV in other rows (I have not scored for delete) are disabled.

How to preserve value LOV so it will remain also after I deleted some lines?

P.S. I've tried autosubmit = "true" - it did not help

It is expected because I see that you rerun the query.

Once you re - run, it retrieves from the database again. Thus, your values are lost because they are not posted.

I don't think that run query is necessary, try to have a programmatic part trigger on the table after you remove all of the lines.

Thank you

Alisson.

Tags: Java

Similar Questions

  • Reduce the length of the array without resetting the table

    An application for review of experience, I would like to use a table for the entry of the experimenter.  The experimenter type in the values they choose, usually less than ten years, and the LabView program to use each value based on the size of the array.  All is good on any other installation requiring more values and the initial installation, the table will grow well.  The following configuration should require fewer values that table continues to impose values for diversity is entered until the table is initialized on start.  A reset button resets the table obviously but requires an additional control, training of users and frustration when forgotten and values entered before resetting.  Is it possible, for example to remove surplus values, to reduce the size of the array?

    Moreover, can the tab or enter key to move between the values in the table?

    Try this. I don't have time to clean it up right now.

  • reset the table

    Hello

    I'm unable to reset the values in the table, once I hit the clear button clears values, but when I buy again, it remembers the old values. But if I re - run the VI then table is reset and old values are not stored. Can someone help me how to clear the values of the table, so that after the loading of new values and to rid the table he doesn't remember the old values. I enclose the vi with this post. Please take a look.


  • I'm looking to add a button to reset the table of contents (collapse of all books)

    Our users get lost in the open books - Yes, I know it's a completely different problem, but I was asked to add a button to "reset" the TOC books to reduce all the books.

    We use IE 8 and HR 10

    I looked everywhere for existing javascript that would do this, but I'm not. Is this something that someone else has already done? I'm not a person of script.

    Thank you!

    Laura

    Well, see if it works.

    Rather than use the link option, click the option for JavaScript.

    Type the following code in the OnClick field:

    parent. Location ='http://www.desiredsite.com/News_Feed.htm'

    Dismiss all dialogs, regenerate and test.

    See you soon... Rick

  • Deletion of rows in a table while the filter condition is in another table

    Hi all

    I am facing a problem of deletion of a row in a table where the condition is in the other table. To ealaborate the scenario further Let's say I have two tables T1 (the transactions table) and T2 (Master Table). I want to delete a record in the table T1 by checking conditions lies in table T2.
    I tried with the query below, but this request deletion of records in the table two.

    DELETE FROM (SELECT * high INNER JOIN T2 on T1 page TP)
    THE top. TID = TP. TID
    WHERE at the top. DEAL_SITE_ID = inputparameter1
    AND (TP. SEGMENT <>inputparameter2 OR tp.segment is not null));

    Here the record is deleted in the two tables, but I don't want to delete the data in my table master i.e table T2.

    Any help would be much appreciated. Thanks in advance.

    Kind regards
    Delphine
    SQL> select *
      2   from the_table;
    
    X          Y
    ---------- ----------
    AA         a
    BB         a
    CC         a
    AA         b
    DD         b
    
    SQL> select *
      2   from the_table_2;
    
    X          Y
    ---------- ----------
    AA         a
    BB         a
    CC         a
    
    SQL>  delete from
      2  (
      3  select *
      4  from the_table  t1 inner join the_table_2 t2
      5  on  t1.x = t2.x
      6  and t1.y = t2.y);
    
    3 rows deleted.
    
    SQL> select *
      2   from the_table;
    
    X          Y
    ---------- ----------
    AA         b
    DD         b
    
    SQL> select *
      2   from the_table_2;
    
    X          Y
    ---------- ----------
    AA         a
    BB         a
    CC         a
    
  • How to reset the table selection

    Hello

    JDev 11.1.2.4

    I displays a table with the unique selection of lines. The first line is selected by default. I would like to reset this selection, so no row is selected. I wrote that code but it does not work:

    RKS RowKeySet = table.getSelectedRowKeys ();

    _logger.info ("RKS" + rks.getSize ());

    rks.removeAll ();

    _logger.info ("RKS" + rks.getSize ());

    RKS. Clear();

    _logger.info ("RKS" + rks.getSize ());

    table.setSelectedRowKeys (rks);

    Whenever rks.getSize () returns the value 1. It seems the removeAll or clear do not work.

    I also try to the current line of the null value, but it does not work either.

    Thank you

    The first line is selected by default. I would like to reset this selection, so no row is selected.

    Well, components interface user are related to the default line set so they will always be 'select' some row.

    You can try to remove selectedRowKeys property of your table (so this should remove selection effect), but the iterator will probably continue to point to the first line in all lines.

    Dario

  • Script to remove all rows from a table except the first

    Please see the screenshots for the question/radio button I'm scripting.  If 'No' is clicked, I want to delete all lines except the first.  Therefore, if the first user clicks Yes, adds a bunch of lines and then click on no, I want all the extra lines should be deleted.  I use the script below, but it removes only half of the lines at a time.  I have to click No. 2 - 3 times to remove all the lines.  Appreciate any help!

    // remove extra rows that may have been added
    var rowCount = Page2.UserList.Table1._RowUserName.count;
    for (var i=0; i<rowCount; i++) {
      Page2.UserList.Table1._RowUserName.removeInstance(i);
    }
    
    

    LCD1.png

    lCD2.png

    Hello

    You can directly use the method setInstances of the instanceManager as follows:

    Page2.userlist.Table1._RowUsername.setInstances (1);

    I hope this will help you!

  • Only reset the names of table of contents?

    Is there any method of resetting the table of contents without impact on the custom groups? I have a lot of groups I place directly in the table of contents, and now I need to insert a new slide that should appear in the table of contents. Hit the reset TOC button will add new slides and insert the name of the slide in the table of contents, but then I have to Setup custom all my groups of TOC. All I can do to avoid this? I suppose not, but thought I would check.

    I'm sorry, but the answer is no. I've learned since TOC appeared to create and modify only after completing the project. BTW the highest group level, you can group slides into the film, the name of the group will be included in the table of contents. If you want more than one level of grouping, the subgroups can be created in the table of contents, not in the film.

  • Record in the table don't is not updated correctly after sail of detail page

    I have 2 jspx pages (page A) a table showing the employee record, another a (page B) is used to update the file of the selected employee. On the page, when the button select a folder and clicking on the 'details' I may be navigaed at pag B on which I can edit registration information in a form component. I have a table column 'Prospect', which applies to a LOV layer VO pageB I use < af:inputComboboxListOfValues > to display a combo of LOV for this attribute, when I enter a new value here and save it, I can go back to page one, but the name of the team for this record shows empty, by querying the database that I find the record updated successfully with the changed value. And when I reloaded the page this record may indicate the new team name value. Why it is not updated in the employee table, when browsing immediately return of page B? I put the table attribute to 'always', but always refresh iterator not. Can anyone help with this? Thank you!!

    BTW, for the other columns (not LOV), they are ok, the table can display the value correctly.

    Published by: user774592 on July 14, 2011 19:56

    Published by: user774592 on July 14, 2011 21:59

    What component to use to show as filed?

  • delete the table (richeTableau), but the reverse lines

    Hi all

    I've seen many messages and articles on how to remove lines of a multi select table and it works fine, BUT I want to remove rows from a table of multi selection when it is not selected.
    The use case is that the user is presented with an array of lines. They choose 1 or more lines and press a button. This button calls a bean managed to remove the lines that are NOT selected.

    I have the code where I have a table of (RowKeySet) of the selected lines. I have problems with this Board (only selected lines) to the rear for the user can display.

    Does anyone know how I can do this in the ADF.

    I use ADF 11 g

    Any help would be great.

    Thank you

    It will not work. The problem is that an adf table consists of a user interface model (see you) and the data model in the link layer. If you do not keep the synchronized you run into trouble.

    The getSelectedRowKeys() simply returns the currently selected lines in the table. If you add or remove a key of all you do not change the selection, not the underlying data in the table.

    On the way, you can try to solve, is to add an attribute that is transitional to the data of the table model, you use as discriminant lines to display or not. It's just that you put a (Boolean) check box in the table to select the rows that you want to use later.
    In this way, you can just use this field as a filter and the framework made the rest.

    Timo

  • How reatin advanced Paggination in the table?

    Hello world

    I'm having a problem with pagination.

    According to the default behavior of paggination my advanced table displays the first page every time I update or delete performed.

    Now in my VO, there are about 300 documents and if I'm on page 5 and remove this record or update the record I should be back on page 5 after the page is rendered.

    Can someone please help me ho control this paging programmatically.

    Thanks in advance.

    Kind regards

    Muriel


    Hello

    Please check your update or remove logic that you are not reset the table lead VO.

    If you reset VO table advance and maintain AM then it will help on the same set of rows.

    Kind regards

    Sandeep M.

  • Problem with the creation of the table using the parallel Council DEC

    Hello

    We have a database table (CARDS_TAB) with the 1,083,565,232 lines and has created a replica table called T_CARDS_NEW_201111. But the count in the new array is 1,083,566,976 the difference is row of 1744. I have no idea how the new table can contain more lines compared to the original table.
    Oracle version is 11.2.0.2.0.

    The two head of table were taken after creating the table. Script that was used to create the replica table is:
    CREATE TABLE T_CARDS_NEW_201111
    TABLESPACE T_DATA_XLARGE07
    PARTITION BY RANGE (CPS01_DATE_GENERATED)
    SUBPARTITION BY LIST (CPS01_CURRENT_STATUS)
    SUBPARTITION TEMPLATE
      (SUBPARTITION T_NULL VALUES (NULL),
       SUBPARTITION T_0 VALUES (0),
       SUBPARTITION T_1 VALUES (1),
       SUBPARTITION T_3 VALUES (3),
       SUBPARTITION T_OTHERS VALUES (DEFAULT)
      )
    (
      PARTITION T_200612 VALUES LESS THAN (TO_DATE(' 2007-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        TABLESPACE T_DATA_XLARGE07
      ( SUBPARTITION T_200612_T_NULL VALUES (NULL)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_200612_T_0 VALUES (0)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_200612_T_1 VALUES (1)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_200612_T_3 VALUES (3)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_200612_T_OTHERS VALUES (DEFAULT)    TABLESPACE T_DATA_XLARGE07 ),
      PARTITION T_200701 VALUES LESS THAN (TO_DATE(' 2007-02-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        TABLESPACE T_DATA_XLARGE07
      ( SUBPARTITION T_200701_T_NULL VALUES (NULL)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_200701_T_0 VALUES (0)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_200701_T_1 VALUES (1)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_200701_T_3 VALUES (3)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_200701_T_OTHERS VALUES (DEFAULT)    TABLESPACE T_DATA_XLARGE07 )
    .
    .
    .
    .
    .
      PARTITION T_201211 VALUES LESS THAN (TO_DATE(' 2012-12-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        TABLESPACE T_DATA_XLARGE07
      ( SUBPARTITION T_201211_T_NULL VALUES (NULL)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_201211_T_0 VALUES (0)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_201211_T_1 VALUES (1)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_201211_T_3 VALUES (3)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_201211_T_OTHERS VALUES (DEFAULT)    TABLESPACE T_DATA_XLARGE07 ),
      PARTITION T_201212 VALUES LESS THAN (TO_DATE(' 2013-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
        TABLESPACE T_DATA_XLARGE07
      ( SUBPARTITION T_201212_T_NULL VALUES (NULL)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_201212_T_0 VALUES (0)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_201212_T_1 VALUES (1)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_201212_T_3 VALUES (3)    TABLESPACE T_DATA_XLARGE07,
        SUBPARTITION T_201212_T_OTHERS VALUES (DEFAULT)    TABLESPACE T_DATA_XLARGE07 )
    )
    NOCACHE
    NOPARALLEL
    MONITORING
    ENABLE ROW MOVEMENT
    AS
    SELECT /*+ PARALLEL (T,40) */ SERIAL_NUMBER     ,
      PIN_NUMBER        ,
      CARD_TYPE         ,
      DENOMINATION      ,
      DATE_GENERATED    ,
      LOG_PHY_IND       ,
      CARD_ID           ,
      OUTLET_CODE       ,
      MSISDN            ,
      BATCH_NUMBER      ,
      DATE_SOLD         ,
      DIST_CHANNEL      ,
      DATE_CEASED       ,
      DATE_PRINTED      ,
      DATE_RECHARGE     ,
      LOGICAL_ORDER_NR  ,
      DATE_AVAILABLE    ,
      CURRENT_STATUS    ,
      ACCESS_CODE        from CARDS_TAB T
    /
    Database CARDS_TAB table also has a primary key on the column Serial_number. When you try to create a primary key on the new table he throws Exception:
    ALTER TABLE T_CARDS_NEW_201111 ADD
      CONSTRAINT T_PK2_1
     PRIMARY KEY  (SERIAL_NUMBER) USING INDEX
     TABLESPACE T_INDEX_XLARGE07
     PARALLEL 10 NOLOGGING;
    
      CONSTRAINT TP_PK2_1
                 *
    ERROR at line 2:
    ORA-02437: cannot validate (T_PK2_1) - primary key violated
    Thanks in advance.

    With respect,
    Adeline Faure

    For parallel processing the documentation suggests the use automatic degree of parallelism (determined by the system running) or by choosing a power of 2 value
    Look at the post by Florian in your currently neighbor post How to remove duplicate rows from a Table to locate the violations (apparently due to parallel processing)

    Concerning

    Etbin

  • Incorrect time in the table of contents

    I have a 8 s sliding for more than a minute long. After mounting, the TOC always shows the time 01:26 and does not update. Saved as a new file, no change.

    Clues?

    I have tried resetting the table of contents, but duration of slides is adapted in real time, no reset necessary.

    Type securities, may I offer a tip? Label the slides instead of typing the slide titles in the table of contents. For a higher level, group slides, labeling the Group and this will appear as a top level heading in the table of contents. This has not only the advantage that resetting the table of contents will keep these labels, but they are also very useful in other cases, some examples:

    • If you want to use the jump to the slide, you can choose the label of the slide instead of the number
    • The advanced interaction, in the branching view, you'll see labels for slides instead of numbers
    • You can reduce the groups in the film strip
    • You can apply a master slide to a group

  • Droping a table from within a procedure by passing the name of the Table as an Argument

    HII All

    I want to remove a table from a procedure dynamically passing the table name as a parameter of a procedure manual

    to do this, I wrote the following procedure

    CREATE OR REPLACE PROCEDURE DEL_TAB (TAB_NAME IN VARCHAR2) AS

    V_TAB_NAME VARCHAR2 (10);

    V_STMT VARCHAR2 (50);

    BEGIN

    V_TAB_NAME: = TABLE_NAME;

    V_STMT: = 'DROP TABLE' | V_TAB_NAME;

    RUN IMMEDIATELY 'V_STMT ';

    DBMS_OUTPUT. PUT_LINE(V_TAB_NAME||) e TABLE DELETED ');

    END DEL_TAB;

    but whenever I'm execute it gives me an error

    ERROR on line 1:

    ORA-06550: line 1, column 15:

    PLS-00357: Table, view or sequence of reference 'A' not allowed in this context

    ORA-06550: line 1, column 7:

    PL/SQL: Statement ignored

    Please tell me the solution...

    Thanks in advance

    Alisson

    Why do you want to implement this procedure? If you want to remove a table just issue the DROP of stand-alone statement. Why write a procedure for this? Also you must understand the difference between REMOVE and DROP in the context of RDBMS. You either use them which is incorrect. DELETION is to remove rows from a table and DROP is to remove the database table.

    And with regard to your problem

    > RUN IMMEDIATELY 'V_STMT ';

    This should be

    immediately run v_stmt;

    You closed the V_STMT variable is in single quotes. You must remove the apostrophes.

  • Need help to insert rows in the table to a custom table area

    Hi all

    I have a requirement as below.

    I have a page of the i invoke a popup search page and displaying the table data in the area of the table, this table I select lines and pressing the button and given in the basic page in the region of the table being filled, of data, I need to insert these lines into a custom table. Please help me how to achieve this. Basically, I need to insert rows from one table to a custom table region.

    Thnaks

    Hello

    Review the link, below, may be it will help you:

    https://forums.Oracle.com/thread/953885

    https://forums.Oracle.com/thread/2151775

    Please share your solution here, it will help others.

    Concerning

    Mahesh

Maybe you are looking for