Issue in ADF Table Refresh

Hi All,
I have a requirement where I need to change the timezone and display the dates in a Table. There is a dropdown above table and as the user changes the
timezone value ,the dates changes accordingly in the Table.
The following steps are followed to achieve this:
1) The following attributes are present in the DB object on which the EO(TaskTableEO) is based :
- TASK_ID
- TASK_NAME
- TASK_NUMBER
- TASK_OWNER
- END_DATE
- START_DATE
- SUMMARY
2) VO Query :
SELECT TaskTableEO.TASK_ID,
TaskTableEO.TASK_NAME,
TaskTableEO.TASK_NUMBER,
TaskTableEO.TASK_OWNER,
test_util.convert_timezone(TaskTableEO.END_DATE,:timezone1) END_DATE,
csf_util_pvt.convert_task_table_timezone(TaskTableEO.START_DATE,:timezone2) START_DATE,
     TaskTableEO.SUMMARY
FROM TASK_TABLE TaskTableEO
Note that the timezones are converted in the VO based on the bind parameter passed to the function test_util.convert_timezone. The function returns the date converted to
the timezone specified.
When the value is changed in the dropdown , the value change listener is called. The timezone selected is picked, the bind variables is set , executeQuery()
is called on the VO , and the table is refreshed . But the date does not show the change in Timezone , but instead it take the default from database.
Can you please suggest if am missing something. Also let us know if we can achieve this using some alternate method.
     Sample Code in Managed Bean:
BindingContext bindingctx = BindingContext.getCurrent();
oracle.binding.BindingContainer bindings = bindingctx.getCurrentBindingsEntry();
DCBindingContainer bindingsImpl = (DCBindingContainer) bindings;
DCIteratorBinding dciter = bindingsImpl.findIteratorBinding("TaskVO1Iterator");
ViewObject vo =dciter.getViewObject();
vo.setNamedWhereClauseParam("timezone1",tzId);
vo.setNamedWhereClauseParam("timezone2",tzId);
     vo.executeQuery();
     RichPanelCollection rpc = (RichPanelCollection)ADFUtil.findComponentInRoot("taskPc");
System.out.println("RichPanelCollection : " + rpc);
AdfFacesContext adfCtx = AdfFacesContext.getCurrentInstance();
adfCtx.addPartialTarget(rpc);

Why not using declaratively dropdown to partialTrigger in table?
However, instead of panelcollection, try refreshing table instance in code.

Similar Messages

  • Scrollbar refresh issue in ADF Table

    Hello, All
    We have an issue regarding the ADF Tables. Please let me know if it is a Oracle bug. All of us know that 'ExecuteQuery' operation refreshes the cache in View Objects.
    But, based on our testing results, there might be a table refresh issue on vertical scrollbars after this opertion is executed.
    Settings:
    In the attached example project, we have a ADF RichTable included in a PanelCollection.
    In addition, We set 'AutoHeightRows' property on this ADF RichTable in order to show scrollbars on the PanelCollection.
    Furthremore, a standard CommandButton is created on the toolbar to execute queries.
    Experimental Steps:
    1. Use your mouse to move the vertical scrollbar to around the center of its range. This behavior causes the scrollbar scrolling vertically.
    2. Click on any row showing in the table right now, make it to be the active row.
    3. Press the 'ExecuteQuery' button, waiting for the table refresh.
    Results:
    1. Active row moves to the first row in the rowset.
    2. Vertical scrollbar stay in the center of its range without moving to the first row.
    3. The first row is hidden from end users. The user can not see the active row in this case.
    FYI:
    The attached project can be accessed from the following link:
    http://www.4shared.com/zip/Xn4Ki0DP/Application3.html
    In this project, we tried to set 'partialTriggers' on RichTable and its surrounding PanelCollection separately. But, the refreshing issue still exists.
    Regards,
    David He

    Welcome David to forums.
    Always mention your exact Jdev version. For more information read this: https://forums.oracle.com/forums/ann.jspa?annID=56
    I too faced the similar kind of issue in one of my application.
    As you have not mentioned the exact jdev version, I will tell you what I did in my application which was developed using Jdev 11.1.2.0
    After the VO is executed, you can write the below line of code to show the first rows in the table.
    applicationsRichTable.setDisplayRow(applicationsRichTable.DISPLAY_ROW_FIRST);
    //applicationRichTable is the binding for the RichTable in managed beanHope it helps.

  • Issue with ADF table range paging and sorting

    Hello,
    We have a requirement to support pagination in ADF tables. For this, we have made use of Range paging access mode in the view object level. The paging works perfectly fine with this. But we have another requirement of letting the user do a sort on the table (Yes!! The paginated table). The sort should be applied on all rows in the db and the control should return to the first row.
    Applying sort as it is provided by the fwk, sorts the records in the obtained range only. So we have over ridden the Sort listener in Managed bean for this and are able to acheive the sorting of all rows through a AM method call. We are seeing a problem after this. If the sort action is applied to the key attribute then the previous and next range navigation works fine. If the same action is applied to non-key field, then some times (yea!! This is not consistent) the next set is not fetched.
    Here is the code snippet that is called on Next navigation:
    Map<String,Object> pfScope = AdfFacesContext.getCurrentInstance().getPageFlowScope();
    Object objPageNumber = pfScope.get("pageNumber");
    int pageNumber = 0;
    if(null != objPageNumber)
    pageNumber = new Integer(objPageNumber.toString()).intValue();
    BindingContainer bindings = BindingContext.getCurrent().getCurrentBindingsEntry();
    JUCtrlRangeBinding view = (JUCtrlRangeBinding)bindings.getControlBinding("GeDmRequestVO");
    int iRange = getTable().getAutoHeightRows();
    int currentPage = view.getIteratorBinding().getNavigatableRowIterator().getRangeStart()/(iRange + 1);
    System.out.println("Before " + view.getIteratorBinding().getNavigatableRowIterator().getRangeStart());
    System.out.println("Current : " + currentPage);
    System.out.println("Page Number : " + pageNumber);
    System.out.println("Range : " + iRange);
    System.out.println("Value : " + iRange*(currentPage + pageNumber));
    view.getIteratorBinding().getNavigatableRowIterator().scrollRange(iRange*pageNumber);
    System.out.println("After " + view.getIteratorBinding().getNavigatableRowIterator().getRangeStart());
    Although, the new values are not refreshed in the table, the SOPs for before and after print the proper range sizes. And as I mentioned above, the above code works perfectly fine if there is no sort applied or when key attribute is sorted.
    Would appreciate your help on this regard with navigation after non-key attribute sort.
    Thanks,
    Chitra.

    Hi Chitra,
    Can you specify some links to implement RangePaging.....We need to implement pagination.If possible can you share the code or specify the steps how you achieved it.
    Thanks

  • Strange issue with ADF table in chrome browser

    I have ADF table which should display 23 rows, but only 20 rows are visible in chrome browser, but other browsers like IE, firefox displays the 23 rows correctly. I have used default ADF table with Drag&drop behaviour in this table. All the 23 rows exported correctly to Excel with export to Excel behaviour and inspect page source also shows all the rows in Chrome browser, but display in the adf is only problem in chrome browser. We're having a production issue with this, any ideas are appreciated.
    Thanks,
    Surya

    Hi All,
    Is this issue fixed yet? There are a couple of threads reporting this issue and the original thread has been Archived. It is a real issue, and it remains an issue. The Chrome browser cuts off the last row of a table in the display. IE displays the row correctly. I am working with JDev 12.1.2 and I am building an application using ADF Tables. Without exception, on every page that has one, the last row of the table is cut off from display in a very ugly way and you cannot scroll down to display the full row. I have tried wrapping the table in a Panel Collection - same result, I have tried setting the height of the table - same result. I have tried surrounding the table with a PanelGroupLayout component (layout set to scroll) - same result. I have even tried surrounding the table with a PanelHeaderComponent component, Type set to both default and Stretch - yes, you guessed it, same result! I've even put the table in the middle of a PanelStretchLayout component - but the last row is always cut off.
    This should be easy for you to reproduce, just drop a data control on a ADF page and select a table. When you view it in the Chrome browser and you will see what I'm talking about. I'm using Google Chrome version 31.0.1650.63 m.
    I have experimented with AFStretchWidth and AutoHeightRows (as suggested by previous threads), nothing seems to work.
    Here's another suggestion, if the forum would allow you to insert an image, I could actually show you what I'm talking about. Food for thought perhaps?
    Best regards,
    Nigel
    "Life's too short not to use ADF"

  • ADF table refresh on update of database field in the background

    Hi,
    I have an ADF Read Only table based on Toplink mapping for a database table. In my scenario, one of the columns (Name) gets updated in the background (through DB adapter from ESB.
    The problem is the ADF table does not refresh to reflect the updated name, on navigating to other pages and coming back (basically page reload).
    The updated name does not reflect until I logout of the session.
    I have used the explicit refresh option for the "findALL" method used by the ADF table. I have also tried setting "NoIdentityMap" option in Toplink Identity Map.
    Please let me know how can I get the table refreshed. I'm using JDev 10.1.3.1 with Toplink.
    Rgds
    Vikas

    I have same problem, and I tried af:poll . It only works when I insert a new record or delete a new record. It doesn't work when I update records.
    I followed this example from Frank Nimphius
    http://thepeninsulasedge.com/frank_nimphius/2007/09/18/adf-faces-using-afpoll-to-refresh-a-table/
    Plus the selection action is not work at all. (My case is multiple selection).
    I just want to know is it possible using af:poll conponment to autorefresh ADF table when I update a record ?
    JDeveloper 10.1.3.3
    Message was edited by:
    xpp

  • ADF table refresh

    Hi All,
    <<Jdeveloper Studio Edition Version 11.1.2.3.0>>
    I have a ADF table with EditingMode as "click to edit", so user can edit only one row at a time.
    My requirement is as below
    1. Table should be refreshed every 5 mins
    2. If the user is in the middle of editing a particular row and the table is refreshed, the values entered by the user should not be reset.
    Is there any way of doing this.
    Thanks in advance
    Best Regards,
    bnkr

    DCIteratorBinding iter = bindings.findIteratorBinding("Iterator");
    RowSetIterator rs = iter.getRowSetIterator();
    while (rs.hasNext()){
                   Row r = rs.next();
                   r.refresh(r.REFRESH_WITH_DB_ONLY_IF_UNCHANGED);
    You need to reset your RowSetIterator because this while loop will execute only for first af:pool event.
    Also, it's not good idea to iterate through default RowSetIterator because UI components are bound to this iterator(you can iterate, but then you need to add logic to restore current row...)
    Instead, try something like this:
    RowSetIterator rs = iter.getViewObject().createRowSetIterator(null);
    while (rs.hasNext()){
        Row r = rs.next();
        r.refresh(r.REFRESH_WITH_DB_ONLY_IF_UNCHANGED);
    rs.closeRowSetIterator();
    Dario

  • ADF Table Refreshing?

    Hi,
    I have a problem with my ADF table which needs to be resolved ASAP. Somebody please help me here..Here are the details..
    I have an ADF table based on a VO.
    I Have a parameter to this view object and i am defaulting a value to this parameter
    I created a parameter form by draggign and dropping the "ExecutewithParams" operation.
    Now, when the page was loaded, the data looks good. When i change the parameter value and click on the executewithParams button, i see rows being repititive.
    When i run teh same query with these 2 parameter value in sql or Toad, i see correct results. Do i have to refresh the table or anything?
    Thanks,
    Lakshmi.

    As always, you should give us your jdev version...
    Have you tried this with -Djbo.debugoutput=console set as start parameter? This will show you the query generated when you query the VO.
    Timo

  • Issue with ADF:Table, always getRowIndex() is returning first row.

    Hi Friends,
    I am working on adf:table and trying to get the selected row of the table. I always get rowindex as 0.
    I am using the following code in my Bean:
    UIXTable searchTable = getEmpTable();
    FacesCtrlHierNodeBinding rowdata =
    (FacesCtrlHierNodeBinding) searchTable.getRowData(searchTable.getRowIndex());
    jsff code:-
    <af:table value="#{bindings.EmpTRVO.collectionModel}"
    var="row"
    rows="#{bindings.EmpTRVO.rangeSize}"
    emptyText="#{bindings.EmpTRVO.viewable ? 'No data to display.' : 'Access Denied.'}"
    fetchSize="#{bindings.EmpTRVO.rangeSize}"
    rowBandingInterval="0" id="t2"
    contentDelivery="immediate"
    autoHeightRows="#{bindings.EmpTRVO.estimatedRowCount}"
    binding="#{pageFlowScope.Bean.EmpTable}"
    styleClass="AFStretchWidth"
    rowSelection="single"
    selectionListener="#{bindings.EmpTRVO.collectionModel.makeCurrent}">
    Please suggest !
    Thanks in advance.

    Which jdev version do you use?
    You can use the current row of the iterator the take use.
    DCIteratorBinding iterBind= (DCIteratorBinding)dcBindings.get("te stIterator"); String attribute = (String)iterBind.getCurrentRow().getAttribute("field1");Timo

  • Issue with ADF Table bound to a View Object Iterator??

    Can anyone say what would prevent an ADF table bound to a View Object Iterator from displaying all the records retrieved by the View Object Query?
    I ran the query directly from sqlplus and it returned 21 rows, However when i use the same exact query in my view object and display the result in a ADF table, only 10 rows are retrieved and displayed in the table ?
    Help .. Please ???

    The ADF table is actually set to use 'Include Range Navigation' and to display 20 rows each time. However, only a 10 rows are retrieved and displayed and the other 10 rows are displayed as blanks with only the Table selection radio buttons in the Select Column.
    e.g.
    Select Data1 Data 2
    o xxxxxx xxxxxx
    o xxxxxx xxxxxx
    o
    o
    o
    o
    The four 'o' are blanks even though there is data to be displayed.

  • ADF Table refresh odd behaviour: is it a bug?

    Hi,
    I am using JDev 11.1.2.3.0.
    I found a strange behaviour of ADF table, that looks like a bug.
    I am using the following scenario:
    1). I have a page with a table on it. The table displays the VO content and all it's columns are filterable.
    2). There is another more complex filter with one parameter. The filter is always applied in addition to all existing filters and is implemented in VO implementation class by overriding the  buildWhereClause() method. The parameter value is stored in the VO as a property, and the property setter is exposed via client interface.
    3). The filter parameter value is specified using Select One Choice component, the value is stored in the pageFlowScope variable (AutoSubmit=true).
    4). The filter parameter setter is binded in the PageDef file as a method action and obtains the value from the corresponding pageFlowScope variable. When user press a button, the filter should be applied. The button has PartialSubmit=true, the table has a reference to the button in the PartialTriggers.
    Here is some code:
    // MyViewObjectImpl code fragment
    private String filter;
    public String getFilter() {
      return filter;
    public void setFilter(String filter) {
      boolean valueChanged = true;
      if (this.filter != null && filter != null) {
        valueChanged = !this.filter.equals(filter);
      this.filter = filter;
      if (valueChanged) {
        clearCache();
    // Backing bean code fragment
    private RichTable table;
    public void setTable(RichTable table) {
      this.table = table;
    public RichTable getTable() {
      return table;
    public String onApplyFilter() {
      BindingContainer bc = BindingContext.getCurrent().getCurrentBindingsEntry();
      OperationBinding op = bc.getOperationBinding("setFilter");
      op.execute();
      FilterableQueryDescriptor fm = (FilterableQueryDescriptor)table.getFilterModel();
      table.queueEvent(new QueryEvent(table, fm));
      return null;
    All works fine except for one thing: the 26-th row of the table always remains from the previous filter value. More precisely, this number equals to iterator RangeSize+1.
    Is this my fault or a bug?
    Thanks.

    Sorry, I forgot about the detailed instructions.
    1). Setup database connection to match the real DB server address, username and password.
    2). Run the ViewController project.
    3). Choose character 'a' in the filter and push "Apply". This will give the countries, ending with the letter a.
    4). Change filter to 'e' and push "Apply". This should give the countries, ending with the letter e, but in fact the second row is 'Argentina' (the first row from the previous query). Pressing the button again produces correct results.
    Thanks.

  • ADF Table Refresh/Commit on Delete

    ADF 11g in jDeveloper 11.1.1.1.0
    So, I have an ADF Table component in a panel collection. Within the collection, I added a menu with menu item to delete the current row. The delete row is not being committed. Is there a way to do a row delete in one operation?
    Note:
    I just drug the delete operation form the data control onto the menu item.
    Action Listener: #{bindings.Delete.execute}
    Partial Submit: true
    Edited by: SK Jennings on Aug 13, 2009 10:14 AM
    Added more info
    Edited by: SK Jennings on Aug 13, 2009 10:17 AM

    You can easily solve it if you just bind the table to a property in the bean as it is in the link poste by Frank.
    I usually do it this way. I have not used findComponent().
    My table ID is "table1".Here are a few tests I tried:
        private RichTable rt;
        FacesContext fc = FacesContext.getCurrentInstance();
        System.out.println(rt.getClientId(fc));     // returns something like this : pt1:dynam1:1:drvpc1:table1
        fc.getViewRoot().findComponent("table1");  // returns null
        fc.getViewRoot().findComponent(rt.getClientId(fc));   // returns null, I expected that one to work
        AdfFacesContext.getCurrentInstance().addPartialTarget(rt); // This one works.I hope that helps,
    Valery
    Edited by: Valhery on 2009-9-18 4:16

  • JDev 11g TP4: ADF tables and ADF form pop-ups PPR?

    I was hoping somebody could help me with the following please.
    I'm currently having a bit of an issue with ADF tables and ADF forms embedded in a pop-up, where the wrong record is shown in the popup. I suspect it's a PPR problem but am unsure. My scenario:
    1) I have the following table:
    CREATE TABLE "CHRIS_MUIR_DELETE_ME" (
    "ID" NUMBER(5,0)
    "SOME_COLUMN" VARCHAR2(20 BYTE)
    CONSTRAINT "CHRIS_MUIR_DELETE_ME_PK" PRIMARY KEY ("ID"));2) I have a default ADF BC EO/VO combination for this table.
    3) I have an ADF Faces RC page with a read-only table based on this VO:
    <af:table value="#{bindings.ChrisMuirDeleteMeView.collectionModel}" var="row"
       rows="#{bindings.ChrisMuirDeleteMeView.rangeSize}"
       emptyText="#{bindings.ChrisMuirDeleteMeView.viewable ? 'No rows yet.' : 'Access Denied.'}"
       fetchSize="#{bindings.ChrisMuirDeleteMeView.rangeSize}"
       selectedRowKeys="#{bindings.ChrisMuirDeleteMeView.collectionModel.selectedRow}"
       selectionListener="#{bindings.ChrisMuirDeleteMeView.collectionModel.makeCurrent}"
       rowSelection="single" partialTriggers="myDialog">
      <af:column sortProperty="Id" sortable="false"
        headerText="#{bindings.ChrisMuirDeleteMeView.hints.Id.label}">
         <af:outputText value="#{row.Id}">
            <af:convertNumber groupingUsed="false" pattern="#{bindings.ChrisMuirDeleteMeView.hints.Id.format}"/>
         </af:outputText>
      </af:column>
      <af:column sortProperty="SomeColumn" sortable="false"
         headerText="#{bindings.ChrisMuirDeleteMeView.hints.SomeColumn.label}">
        <af:outputText value="#{row.SomeColumn}"/>
      </af:column>
    </af:table>Note that rowSelection is set to "single".
    3) The page also includes a popup-dialog combo that shows the same data from the table (ie. they're based on the same VO) as an ADF Input Form:
    <af:popup id="myPopUp">
      <af:dialog type="okCancel" id="myDialog">
         <af:panelFormLayout>
            <af:inputText value="#{bindings.Id.inputValue}"
                label="#{bindings.Id.hints.label}"
                required="#{bindings.Id.hints.mandatory}">
               <f:validator binding="#{bindings.Id.validator}"/>
               <af:convertNumber groupingUsed="false" pattern="#{bindings.Id.format}"/>
            </af:inputText>
            <af:inputText value="#{bindings.SomeColumn.inputValue}"
                label="#{bindings.SomeColumn.hints.label}"
                required="#{bindings.SomeColumn.hints.mandatory}"/>
            </af:inputText>
         </af:panelFormLayout>
      </af:dialog>
    </af:popup>Note that the table's partialTriggers is set to the id of the dialog. This implies on return from the dialog, the table will update itself to reflect any changes.
    4) I have a data bound Create commandButton, + a simple Edit commandButton. The Edit button includes an <af:showPopupBehavior> to display the popup:
    <af:commandButton
        actionListener="#{bindings.Create.execute}" text="Create"
        disabled="#{!bindings.Create.enabled}"
        partialTriggers="table1"/>
    <af:commandButton text="Edit">
        <af:showPopupBehavior popupId="myPopUp"/>
    </af:commandButton>If you run the form with the following steps, you can reproduce my issue:
    1) Click the create button, this will create a blank record in the <af:table>
    2) Click the edit button and give the 2 fields values, press ok. Note this is reflected back in the table.
    3) Click the create button, you will now see another blank record in the <af:table>. Note that the current row selection highlight is on the new record.
    4) In the table select the original record, then the Edit button. Oddly the input form is showing the blank record, not the original record even though we selected it in the <af:table>
    This implies to me that I have to hook up a PPR event such that the fields on the popup know to update themselves when the user selects a new row in the table.
    I've tried setting the partialTriggers property for the popup, dialog and individual fields on the popup page to the table id, but this doesn't seem to work.
    Does anybody have any suggestions on how I'm meant to hook up the partialTriggers in this case? I'm at a bit of a loss to know what to do to solve this issue. Is it possible the table selectionListener isn't working?
    Thanks for your help in advance.
    Regards,
    CM.

    G'day gang
    This morning I had a chance to play with Pavle's suggestions, specifically the popup contentDelivery option, and it's solved the issue. Specifically changing the contentDelivery option to lazyUncached was the golden solution.
    As the popup component help states, the default functionality is: "lazy -- the default strategy described above. The content isn't loaded until you show the popup once, but then is cached."
    ....cached being the issue I was seeing.....
    While the lazyUncached options states: "lazyUncached -- the content isn't loaded until you show the popup, and then is re-fetched every subsequent time you show the popup. Use this strategy if the popup shows data that can become stale."
    The nasty thing about the lazy option is the fact that in the dialog it can show the previous cached result (even though you've selected a different record), and you can even appear to edit that cached result in the dialog, but when you press okay in the dialog and return to the previous table, it's updated the record you selected, not the cached result.
    Confusing, but not a bug if you understand the popup contentDelivery options.
    Frank, if you'd like it, I have the simple test case available to send you. But as it's not a bug I wont send it to you unless requested.
    Thanks to both of you for your assistance with this one. Once again your help is much appreciated! :)
    I'll take time out to blog about this in the next few weeks to assist others.
    Thanks & regards,
    CM.

  • Issue with autosubmit selectchoice in adf table

    I have a column in adf:table which has select choice with autosubmit property set. When the value in the select list changes the table has to refresh and so I have set partialTrigger on table to the select list.
    Now the issue is that when a query is performed and the table refreshes to render the query results, the value change listener of the select choice is invoked with mutiple times (based on number of rows ). The new value of the select choice is null. Why does this happen, how can I avoid it?

    hi ,
    can i see the code of the table ?

  • Issue with the partialTrigger on ADF Table

    Jdeveloper Version 11.1.2.3.0
    I have replicated issue with partialTrigger on the table component. Sample application can be downloaded from here . It needs HR schema to run.
    In below sample pageFragment, I can try refreshing adf table in two ways
    1. Set addEmployee button's id in partialTrigger of ADFTable component.
    2. Set addEmployee button's id in partialTrigger of PanelBox component.
    Note the difference - 1st one doesn't work where as 2nd works fine. Do we have any additional constraints when refreshing ADF table using
    partialTrigger ?
    I replicated the usecase in below example :
    PageFragment Structure -
    PanelBox                         
    |                              
    |__ ADF Table                         
    |                              
    |__toolbar facet                    
    |                              
    |__ addEmployee button                
    PageFragment Code
    <af:panelBox text="PanelBox2" id="pb1">
    <f:facet name="toolbar">
    <af:commandButton actionListener="#{bindings.addEmployee.execute}" text="addEmployee2"
    disabled="#{!bindings.addEmployee.enabled}" id="cb1" partialSubmit="true"/>
    </f:facet>
    <af:table value="#{bindings.EmployeesView1.collectionModel}" var="row" rows="#{bindings.EmployeesView1.rangeSize}"
    emptyText="#{bindings.EmployeesView1.viewable ? 'No data to display.' : 'Access Denied.'}"
    fetchSize="#{bindings.EmployeesView1.rangeSize}" rowBandingInterval="0"
    selectedRowKeys="#{bindings.EmployeesView1.collectionModel.selectedRow}"
    selectionListener="#{bindings.EmployeesView1.collectionModel.makeCurrent}" rowSelection="single" id="t1"
    displayRow="selected" partialTriggers="::cb1" styleClass="AFStretchWidth">
    <af:column sortProperty="#{bindings.EmployeesView1.hints.EmployeeId.name}" sortable="false"
    headerText="#{bindings.EmployeesView1.hints.EmployeeId.label}" id="c1">
    <af:inputText value="#{row.bindings.EmployeeId.inputValue}"
    label="#{bindings.EmployeesView1.hints.EmployeeId.label}"
    required="#{bindings.EmployeesView1.hints.EmployeeId.mandatory}"
    columns="#{bindings.EmployeesView1.hints.EmployeeId.displayWidth}"
    maximumLength="#{bindings.EmployeesView1.hints.EmployeeId.precision}"
    shortDesc="#{bindings.EmployeesView1.hints.EmployeeId.tooltip}" id="it1">
    <f:validator binding="#{row.bindings.EmployeeId.validator}"/>
    <af:convertNumber groupingUsed="false" pattern="#{bindings.EmployeesView1.hints.EmployeeId.format}"/>
    </af:inputText>
    </af:column>
    <af:column sortProperty="#{bindings.EmployeesView1.hints.FirstName.name}" sortable="false"
    headerText="#{bindings.EmployeesView1.hints.FirstName.label}" id="c2">
    <af:inputText value="#{row.bindings.FirstName.inputValue}"
    label="#{bindings.EmployeesView1.hints.FirstName.label}"
    required="#{bindings.EmployeesView1.hints.FirstName.mandatory}"
    columns="#{bindings.EmployeesView1.hints.FirstName.displayWidth}"
    maximumLength="#{bindings.EmployeesView1.hints.FirstName.precision}"
    shortDesc="#{bindings.EmployeesView1.hints.FirstName.tooltip}" id="it2">
    <f:validator binding="#{row.bindings.FirstName.validator}"/>
    </af:inputText>
    </af:column>
    <af:column sortProperty="#{bindings.EmployeesView1.hints.LastName.name}" sortable="false"
    headerText="#{bindings.EmployeesView1.hints.LastName.label}" id="c3">
    <af:inputText value="#{row.bindings.LastName.inputValue}"
    label="#{bindings.EmployeesView1.hints.LastName.label}"
    required="#{bindings.EmployeesView1.hints.LastName.mandatory}"
    columns="#{bindings.EmployeesView1.hints.LastName.displayWidth}"
    maximumLength="#{bindings.EmployeesView1.hints.LastName.precision}"
    shortDesc="#{bindings.EmployeesView1.hints.LastName.tooltip}" id="it3">
    <f:validator binding="#{row.bindings.LastName.validator}"/>
    </af:inputText>
    </af:column>
    <af:column sortProperty="#{bindings.EmployeesView1.hints.DepartmentId.name}" sortable="false"
    headerText="#{bindings.EmployeesView1.hints.DepartmentId.label}" id="c11">
    <af:selectOneChoice value="#{row.bindings.DepartmentId.inputValue}" label="#{row.bindings.DepartmentId.label}"
    required="#{bindings.EmployeesView1.hints.DepartmentId.mandatory}"
    shortDesc="#{bindings.EmployeesView1.hints.DepartmentId.tooltip}" id="soc1">
    <f:selectItems value="#{row.bindings.DepartmentId.items}" id="si1"/>
    </af:selectOneChoice>
    </af:column>
    </af:table>
    </af:panelBox>
    Thanks,
    Rajdeep

    Hi Frank,
    Indeed it worked. But I have two queries now :
    1. We are adding employee record using a method called through method action Binding. So shouldn't the bindings be aware of the same .. i mean sychonization of binding layer should happen when method action binding is used ?
    2. Why it works when i apply partialTrigger on panelBox ? Why "employeesViewImpl" code is not required when I apply partialTrigger on panelBox ? Is it a concept that iterator is reexecuted when you refresh parent component ?
    Thanks,
    Rajdeep

  • Refresh adf table and selection row

    Hi,
    I create web application. I have created entity Users from MySQL database and managed Bean. In this managed Bean (sessionScope) is method for connection to database and method for adding new row (data) in database. It works.
    I have 2 problems.
    The first.
    I have form for adding User and commandButton Add.
    How I can refresh (update) adf table after executing SQL command (in commandButton Add) ? Now I must reconnect session.
    The second problem:
    I want to show a panel with data from one row from adf table.
    How I can selection this row in popup ?
    My table:
    <af:table var="user" rowBandingInterval="0" id="t2"
                                                  inlineStyle="margin:20px 30px; width:578pt; height:160pt;"
                                                  value="#{userController.users}"
                                                  rows="15"
                                                  emptyText="#{bindings.UsersprototypView11.viewable ? 'No data to display.' : 'Access Denied.'}"
                                                  fetchSize="#{bindings.UsersprototypView11.rangeSize}"
                                                  editingMode="clickToEdit" rowSelection="single"
                                                  selectedRowKeys="#{userController.selectedUser}"
                                                  selectionListener="#{userController.selectedUser}"> ---- Here I have problem.
                                            <af:column sortProperty="#{user.user_id}"
                                                       sortable="false"
                                                       headerText="ID"                            
                                                       id="c11" width="33">
                                                <af:commandLink id="ot34" text="#{user.user_id}">
                                                    <af:showPopupBehavior popupId="p4" triggerType="action"/>
                                                </af:commandLink>
                                            </af:column>
                                            <af:column sortProperty="#{user.firstname}"
                                                       sortable="false"
                                                       headerText="Firstname"
                                                       id="c20" width="111">
                                                <af:outputText value="#{user.firstname}" id="ot27"/>
                                            </af:column>
                                            <af:column sortProperty="#{user.lastname}"
                                                       sortable="false"
                                                       headerText="Lastname"
                                                       id="c12">
                                                <af:outputText value="#{user.lastname}" id="ot31"/>
                                            </af:column>
                                            <af:column sortProperty="#{user.address}"
                                                       sortable="false"
                                                       headerText="Address"
                                                       id="c9" width="95">
                                                <af:outputText value="#{user.address}" id="ot32"/>
                                            </af:column>
                                            <af:column sortProperty="#{user.city}"
                                                       sortable="false"
                                                       headerText="#City"
                                                       id="c10" width="76">
                                                <af:outputText value="#{user.city}" id="ot33"/>
                                            </af:column>
                                            <af:column sortProperty="#{user.username}"
                                                       sortable="false"
                                                       headerText="Username"
                                                       id="c7" width="102">
                                                <af:outputText value="#{user.username}" id="ot29"/>
                                            </af:column>
                                            <af:column sortProperty="#{user.email}"
                                                       sortable="false"
                                                       headerText="E-mail"
                                                       id="c21" width="106">
                                                <af:outputText value="#{user.email}" id="ot28"/>
                                            </af:column>
                                            <af:column sortProperty="#{user.regdate}"
                                                       sortable="false"
                                                       headerText="Registration"
                                                       id="c8" width="108">
                                                <af:outputText value="#{user.regdate}" id="ot30">
                                                    <af:convertDateTime pattern="#{user.regdate}"/>
                                                </af:outputText>
                                            </af:column>
                                        </af:table>userController is name managed Bean.
    users is list of users.
    My panel window (popup):
    <af:popup childCreation="deferred" autoCancel="disabled" id="p4">
                                        <af:panelWindow id="pw9" title="Delete user">
                                            <af:panelFormLayout id="pfl6">
                                                <af:panelLabelAndMessage label="ID:"
                                                                         id="plam16">
                                                    <af:outputText value="#{userController.selectedUser.user_id}" id="ot50"/>
                                                </af:panelLabelAndMessage>
                                                <af:panelLabelAndMessage label="Firstname:"
                                                                         id="plam17">
                                                    <af:outputText value="#{userController.selectedUser.firstname}" id="ot51"/>
                                                </af:panelLabelAndMessage>
                                                <af:panelLabelAndMessage label="Lastname:"
                                                                         id="plam18">
                                                    <af:outputText value="#{userController.selectedUser.lastname}" id="ot52"/>
                                                </af:panelLabelAndMessage>
                                                <af:panelLabelAndMessage label="Address:"
                                                                         id="plam19">
                                                    <af:outputText value="#{userController.selectedUser.address}" id="ot53"/>
                                                </af:panelLabelAndMessage>
                                                <af:panelLabelAndMessage label="City:" id="plam20">
                                                    <af:outputText value="#{userController.selectedUser.city}" id="ot54"/>
                                                </af:panelLabelAndMessage>
                                                <af:panelLabelAndMessage label="Username:"
                                                                         id="plam21">
                                                    <af:outputText value="#{userController.selectedUser.username}" id="ot55"/>
                                                </af:panelLabelAndMessage>
                                                <af:panelLabelAndMessage label="E-mail:" id="plam22">
                                                    <af:outputText value="#{userController.selectedUser.email}" id="ot56"/>
                                                </af:panelLabelAndMessage>
                                                <af:panelLabelAndMessage label="Registration:"
                                                                         id="plam23">
                                                    <af:outputText value="#{userController.selectedUser.regdate}" id="ot57">
                                                        <af:convertDateTime pattern="#{userController.selectedUser.regdate}"/>
                                                    </af:outputText>
                                                </af:panelLabelAndMessage>
                                            </af:panelFormLayout>
                                            <af:commandButton text="Delete" id="cb18"
                                                              inlineStyle="width:80pt; margin:10px 0px 0px 0px;"/>
                                        </af:panelWindow>
                                    </af:popup>When I cut out row: selectionListener="#{userController.selectedUser}
    Popup (for deleting user) looks like this:
    http://imageshack.us/photo/my-images/404/popupc.jpg/
    I need to get the outputs from <af:outputText> in this popup.
    Thanks for help.
    Edited by: user9202624 on 26.2.2013 7:52

    thanks for answer.
    I added partialTriggers in af:table
    <af:table var="user" rowBandingInterval="0" id="t2"
                                                  inlineStyle="margin:20px 30px; width:578pt; height:160pt;"
                                                  value="#{userController.users}"
                                                  rows="15"
                                                  emptyText="#{bindings.UsersprototypView11.viewable ? 'No data to display.' : 'Access Denied.'}"
                                                  fetchSize="#{bindings.UsersprototypView11.rangeSize}"
                                                  editingMode="clickToEdit" rowSelection="single"
                                                  selectedRowKeys="#{userController.selectedUser}"
                                                  partialTriggers="::t1" >What next ? What should I do next ? Sry, I'm newbie in adf and jDev.
    Edited by: user9202624 on 26.2.2013 8:55

Maybe you are looking for