How to update all the record for a particular column in a table based on search criteria.

Hi All,
I am new to ADF. I have a requirement, where i have to perform mass update on a table.
Scenario:
Ex: I have a dept manual search region. where i search with deptId: 20. I get 20 records in my table. now i have  another region where i have a inputchoice list which contains all the columns names that exists in dept table. Beside that i have a input text box and an update button
Now user, first searches with dept id:20 and clicks on search button, where it shows 20 record in the table. He then select a column from input choicelist(ex: ManagerId), then enters new value in the input box(ex: abc) then clicks on update button.
Now i want, all the records in the ManagerId column with dept id:20 to be updated with the new value "abc"
Can anyone help me with the code.
Thanks in advance..

Hi,
If you go to your VO and generate the ViewObjectImpl, in there you can create a method which will contain two parameters, 1 the attribute name and 2 the value.
Then you can follow something like explained in this post:
ADF Tutorial: How to apply bulk actions to a view object rows
The only difference is that you will need to create a method like this:
public void updateAttribute(String attribute, Integer value){
        RowSetIterator iter = createRowSetIterator(null);
        while (iter.hasNext()){
            Row row = iter.next();
            row.setAttribute(attribute, value);
Then you expose that as a client interface and then after you filter your table by your criteria you just need to execute this method passing the right parameters.
Regards

Similar Messages

  • How to set color for a particular column in advance table?

    How can we set the color of a particular column in advance table based on some parameter feteched from vo query in process request?

    i have tried the same way as mentioned in the post but ,its giving error
    java.lang.ArrayIndexOutOfBoundsException: 0
    processRequest code
    OAAdvancedTableBean table =
    (OAAdvancedTableBean)webBean.findIndexedChildRecursive("TimEntAdvtbl");
    if (table != null)
    System.out.println("table");
    OAColumnGroupBean daily =
    (OAColumnGroupBean)table.findIndexedChildRecursive("DailyColGrp");
    if (daily != null)
    System.out.println("daily col");
    OAColumnGroupBean ColGrp6 =
    (OAColumnGroupBean)table.findIndexedChildRecursive("ColGrp6");
    if (ColGrp6 != null)
    System.out.println("ColGrp6");
    OAColumnBean SatCol =
    (OAColumnBean)webBean.findIndexedChildRecursive("SatCol");
    if (SatCol != null)
    System.out.println("col");
    OAMessageTextInputBean sat1 =
    (OAMessageTextInputBean)SatCol.findIndexedChildRecursive("sat");
    if (sat1 != null)
    System.out.println("sat1");
    OADataBoundValueViewObject csssat= new OADataBoundValueViewObject(sat1,"Color");
    sat1.setAttributeValue(oracle.cabo.ui.UIConstants.STYLE_CLASS_ATTR, csssat);
    Error Page
    ## Detail 0 ##
    java.lang.ArrayIndexOutOfBoundsException: 0
         at oracle.sql.NUMBER._fromLnxFmt(NUMBER.java:3199)
         at oracle.sql.NUMBER.toString(NUMBER.java:761)
         at oracle.sql.NUMBER.stringValue(NUMBER.java:2090)
         at oracle.jbo.domain.Number.toString(Number.java:390)
         at oracle.apps.fnd.framework.webui.OADataBoundValue.formatObject(Unknown Source)
         at oracle.apps.fnd.framework.webui.OADataBoundValue.convertValue(Unknown Source)
         at oracle.apps.fnd.framework.webui.OADataBoundValue.convertValue(Unknown Source)
         at oracle.apps.fnd.framework.webui.OADataBoundValueViewObject.convertValue(Unknown Source)
         at oracle.apps.fnd.framework.webui.OADataBoundValue.getValue(Unknown Source)
         at oracle.apps.fnd.framework.webui.OADataBoundValueViewObject.getValue(Unknown Source)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.getAttributeValueImpl(Unknown Source)
         at oracle.apps.fnd.framework.webui.beans.message.OAMessageTextInputBean.getAttributeValueImpl(Unknown Source)
         at oracle.cabo.ui.BaseUINode.getAttributeValue(Unknown Source)
    Please help

  • How to find out all the OKCODEs for a particular screen?

    I am working on t-code CL20N and trying to record with t-code SHDB, in the second screen when I press enter it is coming out, but when I run CL20N without SHDB it is going through all the screens perfectly, SHDB is not working for CL20N.
    Is there any other way to find out all the OKCODEs for a particular screen/s?

    Hi,
    First look for any push button or menu item which can take you to the second screen instead of hitting enter directly in tcode CL20N . If any such button exist in the TCode, u can use the same button in SHDB also for moving to the  second screen.
    Thanks,
    Rajinikanth G

  • How to update all condition records at a time with some percentage or some

    Dear Sir,
    In PRD system we have more than 600 condtion records.
    Noe desiel hikes happend, due to that client want to update all condition records(600) at a time with required percentage or required value.
    How to update all records at a time
    With regards
    Lakshmikanth

    Hi,
    Through BDC or LSMW first you have to do the recording for particular transaction code and then base on that u have to prepare the flat file to upload the file for the same.
    For BDC programing you have to take the help of ABAP progmer but LSMW you can also do.
    For more information about LSMW plz go to following link :
    [LSMW |http://www.slideshare.net/arun_bala1/sap-sd-lsmw-legacy-system-migration-workbench/]
    [Step-by-Step Guide for using LSMW|www.scmexpertonline.com/downloads/SCM_LSMW_StepsOnWeb.doc ]
    BDC
    [BDC Call Transaction|http://www.sapdevelopment.co.uk/bdc/bdc_ctcode.htm]
    [BDC Recording|http://www.sapdevelopment.co.uk/bdc/bdc_recording.htm]
    But it would be better for you to please contact to your ABAPer for BDC programming.
    Cheers...

  • Periodic Alert-How to send all the records returned from the SQL in a mail?

    Hello all,
    I have defined a Periodic Alert, my SQL query returns more than one record whenever I run it. I also defined an action to send an email with the message consisting of the output variables from the SQL. Whenever i run this alert, a mail is being sent for every single record returned from the query. But i want to send a single mail containing all the records information that my SQL query returns.
    For Example: My SQL query lists all the users created on current date.
    Select User_Id, User_Name into &OUTPUT1, &OUTPUT2
    from fnd_users where trunc(creation_date) = trunc(sysdate)
    Now i want to send a mail with all the users information from the above query, to SYSADMIN. How can this be achieved?
    Thanks & Regards
    chakoo

    Hi Chakoo,
    If the Periodic Alert is not working as requried. You can write a simple package with 3 procedures to implement the writing output to a out file and simultaneuosly send email to multiple receiptents.
    Example:
    Create Package xx_pac
    Create public Procedure P1
    begin
    Select User_Id, User_Name into &OUTPUT1, &OUTPUT2
    from fnd_users where trunc(creation_date) = trunc(sysdate)
    fnd_file.put_line (fnd_file.output, &OUTPUT1, &OUTPUT2);
    end;
    (Create private Procedure P2
    begin
    ---Write the email package using the UTL_SMTP approch. Using this approch you can send the procedure P1 output file as an attachment to the desiginated receiptents.
    end;
    (Create public Procedure P3
    begin
    ---call the procedure P1 using the "g_request_id = fnd_request.submit_request"
    ---Wait for the above procedure to complete using "l_conc_status := fnd_concurrent.wait_for_request" procedure.
    ---call the procedure P2. (When called you must provide the correct to, from address)
    end;
    end;
    Register the Package xx_pac as a concurrent program and schedule when submit it from the request.
    Regards
    Arun Rathod

  • How to fetch all the records from ztable

    Hi 
    My program is outbound program.
    According to the requirement i have to fetch all the records from ztable which are not tranmitted before to the third party and once the records are extracted and written to output file they will be marked as 'X' in the "status" field of that ztable for the next days run.
    How to fetch the records.Please suggest me.
    Thanks,
    Neelima

    HI,
    Fetch all the records whose status is equal to 'X' as whatever data is sent to third party system is marked as 'X' in status field of table after sending.
    You need to first fetch the data into internal table using the select statement where status EQ space. You get the data which is not yet transmitted to third part. And later in the program after trasmitting the data to third party modify the Records in the DB table which are transmitted with Staus eq 'X'.

  • Should I use BCS my backend database will update all the record of the sql table daily.

    Should I use the BCS where the database table is going to be updated daily.
    All the records will be updated on daily basis.
    Why should I use BCS when I can connect to the sql server directly and  update the records that I need.
    What additional benefits can I get from BCS , I do not need the search functionality.
    Regards

    Hi,
    According to description, my understanding is that you want to know if you need to use Business Connectivity Services to connect external SQL table.
    Business Connectivity Services is a centralized infrastructure in SharePoint 2013 and Office 2013 that supports integrated data solutions.
    Business Connectivity Service will provide a familiar user interface to manage sql table data. It is more security for reading and writing data to external sql table.
    Here is a detailed article for your reference:
    https://technet.microsoft.com/en-us/library/ee661740(v=office.15).aspx
    https://msdn.microsoft.com/en-us/library/office/ee556440(v=office.14).aspx
    Best Regards
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Jerry Guo
    TechNet Community Support

  • How to fetch all the records

    Hello everybody,
    I am currently working on SQL Developer for the couple of weeks. I have specific need to check, how much time one query take to fetch all the records. Currently it can fetch only 50 records and when scroll then next 50 records and so on.
    Can anybody tell me, how to set this to fetch full records
    Regards,
    Martand M Joshi

    Martand,
    There's no setting to fetch all records. You wouldn't like SQL Developer to fetch for minutes on big tables anyway.
    If, for 1 specific table, you want to fetch all records, you can do Control-End in the results pane to go to the last record. You could time the fetching time yourself, but that will vary on the network speed and congestion, the program (SQL*Plus will be quicker than SQL Dev because it's more simple), etc.
    Now, what I think you really want here, is getting the execution time. If you really want to analyze the query's performance, you'd have to use the explain plan, autotrace and tkprof (see the manual for tuning and performance).
    To make us life easier, the makers of SQL Developer included support of the explain plan, and as of v1.1, autotrace!
    I'm sure you've got enough to work things out from here...
    Regards,
    K.

  • How to identify all the information for a given company code?

    Hi,
    Our company provides data migration services for SAP and other ERP applications. Our customers provide us the specifications for extractions and conversions. We use one or more 3rd party tools to extract data from legacy systems into text/Excel files. Customers use LSMW to load generated files.
    We just got an unusual request. This customer wants to get ALL the data from SAP for a given company code and dump into Excel. They would do some manual editing on the data and load it into a new SAP client.
    In the past, customers would be more specific in their requirements. For example, they will mention Materials, Customers, Inventory, etc. In this case, the customer simply wants ALL the data for a given company code.
    Q1. Is everything in SAP related to company code, either directly or indirectly? For example, can materials be filtered by company code?
    Q2. The tools that we use let us extract data from SAP using SQL-like queries. How do I identify ALL the tables that I would need for a given company code?
    My feeling is the customer themselves are not clear on what they really want. Perhaps they are expecting us to guide them.
    I would appreciate any thoughts that you may have.
    If there is a more appropriate forum for this question, please let me know.
    Thank you in advance for your help.
    Regards,
    Peter

    hi
    t001w is the master table for plants, u can see all plants in this table.
    regads:
    rajesh.k

  • How to get all the records in the RSA3 extratcion

    Hi All
    i have problem in seeing the records at RSA3. when i load the data im getting around 14k records when i want to see all the records ,i am not able to see that.. but the records are available in tables...
    i want to see the the some asset numbers but for RSA3 its getting me upto 1k records..
    I want to check my datasource is that working properly or not.
    please help me
    regards
    AK

    Thanks alot Bhanu ,,,,
    Actually i was not concentrating on the first screen ...always going to next screen and searching for defferent searching ...
    got the records now thanku very much
    Rewarded points
    Regards
    AK

  • How do I sort so that all the songs for a particular album show up under only one album? Example:  Eminem 'Encore'  has multiple artists on the entire track list.

    Example:  Eminem 'Encore'  has multiple artists on the entire track list.  Several songs will just list Eminem as the artist, but a lot will have Eminem, FEATURING...so and so.  Each song that has "FEATURING" shows up as a different album, so if you are not paying attention, and pull all the songs from a particular album over to your ipod, for example, and you don't see that not all the songs are there, you won't get them all to transfer.
    Is there anyway to correct this?

    Each tune gets a file name - that is how iTunes works. iTunes is a data base manager.
    In a PlayList a reference is created that will link to a specific tune.
    You can take the tunes that you do not want listed under a particular album name and change the album name using 'Get Info' for that tune(s) from the iTunes window.
    MJ

  • How to update all the rows of table using stored procedures

    Hi,
    I want to update all the rows of a table of a specific column
    sp_a  male
    sp_b female
    sp_c  male
    sp_d female
    in above table 
    gender of all the columns has to be interchanged.

    Sir table is like this detail(name varchar(10),gender varchar(10))
    Where Details  are like this 
    Name  Gender
    sp_a 
    male
    sp_b
    female
    sp_c 
    male
    sp_d
    female
    I want to create a stored procedure which automtically updates gender from male to female and female to male
    for all the rows . i.e., all the rows are updated for column gender by just running a stored procedure.
    So after execution of stored proc the above table looks
    Name  Gender
    sp_a 
    female
    sp_b
    male
    sp_c 
    female
    sp_d
    male

  • How to display all the Records of all the "Books of Business" in Report ?

    Hello,
    I have a user with 3 "Books of Business" (No Sub Books).
    I would like to generate a report with the data of the 3 books.
    With the "selector", it seems that I can't choose the "All" option.
    Can someone confirm the behavior ?
    Thanks for your help.

    Hello,
    I do have a similar problem.
    I have already tried to create a parent book (the checkbox "can contain data" is not activated), assign it to sub-books and add first my user as a book user (Admin role). However, when I start a simple report which should show e.g. Number of Contacts in a book an choose the parent book in the book selector I get an error message and there are no results ("The specified criteria didn't result in any data").
    Did I miss any setup steps or is not possible to see all the records at once which belong to the sub-books with a parent book?
    If I pick my user book, I see only the records I own. The problem is that our CEO needs a view there he could see records in sub-books separately but also the records in both of them at once. Unfortunately, the Manager Visibility can not be applied because we have a different hierarchy in the system as it is in real (otherwise wrong data in forecasts).
    Many thanks in advance
    Regards, Vilma

  • How to insert all the records using below loop

    I am iterating value from hash map and store the values in database.
    Below loop structure, the values from hashmap are inserted fine.
    But inside while(rs.next()),first record from db only inserted for all the records
    while(itr.next()){
    Integer key=(Integer)iterator.next();
    String Value=(String) orderNumberMap.get(key);
    while(rs.next()){
    String firstName=rs.getString("fname");
    String lastName=rs.getString("lname");
    insert into tbl values('"+key+"','"+Value+"','"+fname+"','"+lname+"');
    Regards

    Thanks for ur reply. The below is a scenario
    I am having 3 records in a resultset
    firstname= shadik
    lastname frank
    firstname= felix
    lastname sha
    firstname= williams
    lastname= scoot
    To insert above records with key, values retrieved from hashmap as follows
    Number 1
    empid 101
    Number 2
    empid 102
    Number 3
    empid 103
    I need to insert above values in a table and expect a output as follows..
    Number empid firstname lastname
    1 101 shadik frank
    2 102 felix sha
    3 103 williams scoot.
    But output will be displayed as follows
    Number empid firstname lastname
    1 101 shadik frank
    2 102 shadik frank
    3 103 shadik frank.
    Values from HashMap are inserted fine. But retriving from resultset shows only first records for all the rows.

  • How to get all the Record Groups?

    in the form i had created a record group. let us say they are:
      RG_APPR_TYPE_CDE_LIST
      RG_DRV_APPR_TYPE_CDE_LIST
      RG_PROJ_MODE_CDE_LIST
      RG_DRV_PROJ_MODE_CDE_LIST
      RG_PROJ_STATUS_CDE_LIST
      RG_DRV_PROJ_STATUS_CDE_LIST
      RG_ORG_SUB_TYPE_CDE_LIST
      RG_DRV_ORG_SUB_TYPE_CDE_LIST
      RG_REGION_NUM_LIST
      RG_DRV_REGION_NUM_LISTwhen the form hits on the clear button it invoke the CLEAR_FORM. i want to get all the record groups dynmically so i won't have to explicitly call the
      Delete_Group('RG_APPR_TYPE_CDE_LIST');
      Delete_Group('RG_DRV_APPR_TYPE_CDE_LIST');
      Delete_Group('RG_PROJ_MODE_CDE_LIST');
      ...one by one. is there any other workaround? i appreciate any help on this. thanks.

    is there any other workaroundNo.

Maybe you are looking for

  • Safari won't open a new tab

    I'm using Safari 5.0.5 and when I hit command+T or when I right click on a link to open in a new tab, it doesn't open a new tab, it gives me a white page and the URL reads the same page I was previously on. I can't find anything that explains why it

  • Mail on iPad (and iPhone) shows only old emails

    Hello. I have migrated all my gmail emails into @me.com iCloud account. After this, on my mobile devices I can only see a few recent emails and a bunch of old emails (like the once I received in 2008 & 2009). Inbox is like this: 2012: 5/6 emails 2011

  • Error while doing the LO extraction

    Hi Gurus, I am trying to extract data from the purchasing 2LIS_02_ITM data source through LO extraction. While filling the Setup tables in the R3 sytem I got error with the followng message "Maintain conversion factor for USD / DDK(Currecy type M). P

  • Performance issue while inserting data

    I have a .dat file containing the required data for the table.It has almost half a million rows.When i inserted the data using SQL LOADER it took almost whopping 70 minutes .How can i insert the data fast.what should i include in my control file to i

  • BSR code for TDS certificate purpose

    Dear Team, I have maintained BSR code in *Bank branch fields  of  Bank key* for TDS certificate purpose  , But it is not updating correctly in Form 16A (TDS certificate ) and Bank Key has updating instead of BSR code . Please suggest me any other fil