For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!
User, can you describe what you try to archive. Executing an operation will just do that, executing it. If you want to refresh the UI you hae to issue a ppr. However, without more information it's hard to tell which way to go.
Timo
i will use the hard refresh because my information of the TreeTable don't refresh adequately and need use Ctrl + F5 to working and obtain information last updated
Why does the info on hte tree table not refresh?
Beside data model, which is refreshed as per your code snippet, you should also refresh view component (or entire page, which you do with Ctrl+F5). As I dont know how you wish to "trigger" refresh, I'll assume you are doing it from some button. Lets say command / action button which triggers some action in backing bean (doing something in database) so you wish to show updated state in a table. Then you have just to put partialTrigger on your af:table to be the action button (or multiple of them, look into doc for partialTrigger property). Then, after the model is refreshed (as per executing binding action) JSF will rerender also the table view and - you get your data updated!
Also, there is a way to grammatically force refresh of particular table from your code (instead using declarative partialTrigger approach). At the end of your code to refresh model, just add something like:
private RichTable tableBinding;
...
AdfFacesContext.getCurrentInstance().addPartialTarget(tableBinding);
This is i don't know..
Well, if xou don't describe youe whole use case and we can only guess. My guess is as @PaKo already told you that you have to send a ppr to the table or the surrounding layout container (e.g. af:panelCollection). If the change of hte data is invoked by a button, you can do this decoratively by adding the id of hte button to the Table or layout container. If you do t his you should use the Edit option you get if you click on the wheel on the right side of the partial trigger property. This will ensure that you get the right id including any naming containers.
For example, I run the application that shows me a table in the database. If I modify this database physically, when refreshing the page do not see the changes reflected, I need to close the application and re-run. Is the information cached?
This works fro me without writing on line of code. I start with the emp table in the HR db as
in my sample it looks like
as you see equal. Then I change the DB to 24000 and commit to get
Now I hit the refresh declarative button
and get
So I see the new or changes data in the db in my table
All I did was to add a partialTrigger in the table pointing to the refreshButton!
<af:table value="#{bindings.EmployeesView1.collectionModel}" var="row" rows="#{bindings.EmployeesView1.rangeSize}"
emptyText="#{bindings.EmployeesView1.viewable ? 'No data to display.' : 'Access Denied.'}" rowBandingInterval="0" selectedRowKeys="#{bindings.EmployeesView1.collectionModel.selectedRow}" selectionListener="#{bindings.EmployeesView1.collectionModel.makeCurrent}" rowSelection="single" fetchSize="#{bindings.EmployeesView1.rangeSize}" filterModel="#{bindings.EmployeesView1Query.queryDescriptor}" filterVisible="true" queryListener="#{bindings.EmployeesView1Query.processQuery}" varStatus="vs" id="t1" **partialTriggers="::b2"**\>
That's it.
Thanks, is the solution