There was a post about new ADF 11g PS6 feature Table Pagination - ADF 11g PS6 - ADF 10g Table Pagination Feature is Back Finally. I had a question from the reader in the comments, about displaying selected row from the page range other than the first. Reader was saying this doesn't work, indeed I tested it with sample application and it doesn't seem to work. If you plan to implement such use case where display of selected row is important, keep in mind there are related issue in ADF UI table pagination. I will describe them below.
Sample application - TablePaginationApp_v4.zip, contains ADF task flow with two fragments. Single row is selected in the first fragment and we try to display the same row in the table from second fragment:
I will show you first how it works by default. Table is set to display 10 rows per page and we navigate to some row in the next page range:
Press Show Employees button to navigate to the table. Table displays first page range, there is no selected row shown:
You can select manually second page range - you will find selected row there:
This is what blog reader explains in his comment - current row is not displayed.
Let's try to apply one trick and see if it works - DisplayRow = selected for ADF table component:
We test now the same thing - navigate to table of Employees with row selected in other than first range page:
Selected row is displayed now, required page range is loaded automatically from the beginning:
But there is another problem now - you are locked in into current page range. Try to press other range page number, it will be changed - but not data, data remains the same and insist to show selected row:
It seems like we can use table pagination only for such use cases, when there is no need to automatically display selected row. At least until workaround is found.
Sample application - TablePaginationApp_v4.zip, contains ADF task flow with two fragments. Single row is selected in the first fragment and we try to display the same row in the table from second fragment:
I will show you first how it works by default. Table is set to display 10 rows per page and we navigate to some row in the next page range:
Press Show Employees button to navigate to the table. Table displays first page range, there is no selected row shown:
You can select manually second page range - you will find selected row there:
This is what blog reader explains in his comment - current row is not displayed.
Let's try to apply one trick and see if it works - DisplayRow = selected for ADF table component:
We test now the same thing - navigate to table of Employees with row selected in other than first range page:
Selected row is displayed now, required page range is loaded automatically from the beginning:
But there is another problem now - you are locked in into current page range. Try to press other range page number, it will be changed - but not data, data remains the same and insist to show selected row:
It seems like we can use table pagination only for such use cases, when there is no need to automatically display selected row. At least until workaround is found.
I am using 11.5 jdeveloper, as per your example, i have download to local and try to run. but i am getting Error(33,53): cannot find method getScrollPolicy().it seems , my adf 11g table and jeveloper 11.5 is not supporting table page scroll.please let me know any alternative .
ReplyDeleteThis is not as per my example. Per my example you should have JDEV PS6 (11.1.1.7)
ReplyDeleteAndrejus
Hi Andrejus,
ReplyDeletewe are using adf with java pojo objects not with business components.
can you explain me how to implement the pagination with pojo(we are using spring and hibernate for business logic)
1)adf table is having any handler methods to control the pagination?
Thanks in advance
kishore
Not sure. I would use ADF BC instead of POJO.
ReplyDeleteAndrejus
Hi Andrejus,
ReplyDeleteI've also faced this problem, and try many ways to fix that, but no way..
I've searched all in the internet and finded your blog - the only one talk about that's problem..
May be this is a bug of ADF?
Anw, thanks for this blog.