Today I encountered some difficulties refreshing a tabular form without submitting the entire page. My tabular form data depended on the value of a select list (nothing more than a parent-child relation). If you don’t know where I am talking about, please check out the following example.

I started off with writing some JavaScript code to push the selected value into session state. This allows me to use the select list item in the WHERE clause of my tabular form source query. Altering the session state of an APEX select list item can be easily achieved by performing an AJAX call. Put the below code in the Function and Global Variable Declaration text area which can be found in the page attributes:

function setSessionState(pItem) {
  var get = new htmldb_Get(null, &APP_ID., 'APPLICATION_PROCESS=dummy', &APP_PAGE_ID.);
  get.add(pItem, $x(pItem).value);
  gReturn = get.get();
  get = null;

Update on 20-08-2016: the htmldb_Get object has become deprecated in Oracle Application Express 5.0. Instead, use the Page Items to Submit attribute on the tabular form component to push the client-side value into session state.

Make sure to add an onchange event to the select list item so that the above JavaScript function gets executed. To do so, fill in the HTML Form Element Attributes field: onchange=”setSessionState(”.

The next step is to create a dynamic action that fires whenever the value of the select list changes. This dynamic action includes one true action which refreshes the tabular form region. Have a look at the screenshots below to clarify any possible uncertainties.

the dynamic action settings
the dynamic action settings


the true action settings
the true action settings

Now, I thought that this would do the trick since I have used this technique before to refresh interactive and SQL reports. After a little test I noticed that my tabular form didn’t move a thing whenever I changed the value in my select list. What could have possibly gone wrong? I figured out that the session state of my select list item was being set correctly which implies that my dynamic action gets fired.

After some sniffing around, I ran across the tabular form attribute Enable Partial Page Refresh and its default value No. PPR allows you to refresh the report region when paginating forward and backward in your result set, without the need to refresh the entire page. This attribute must be enabled in order to successfully refresh a tabular form with a dynamic action. So simply changing the PPR attribute to Yes solved my issue here.