4 Replies Latest reply on Apr 24, 2012 5:27 PM by 769996

    Apex bug?  Items being cleared in session state - can't figure out why

      I have an item that is being submitted with a value but is then being overwritten and set to null. I can't see any reason why the submitted value is being overwritten with null.

      I have been debugging this problem for most of the day and can't figure out what is happening and was hoping someone in the forum might be able to shed some light.

      Some details:

      The item is on Page 0, has source type of "PL/SQL Expression or Function", a source expression of "V('REQUEST')", and Source Used = "Always".

      I viewed the HTML source of the rendered page and can see the following HTML, so I know the item has a value when the page is rendered:
      <input type="hidden" id="RENDER_REQUEST" name="p_t08" value="EDIT" />

      I have used Firebug to view the HTTP POST body and can see that p_t08 is being correctly submitted with a value of "EDIT" in the post body.

      When I run the page in debug mode and then view the debug log, I see that Apex is indeed setting this item to null:

           0.01500     0.01600     A C C E P T: Request="WIZ_NEXT"
           0.23400     0.00000     Session State: Save form items and p_arg_values
           0.24900     0.01600     ...Session State: Save "BRANCH_TO_PAGE_ID" - saving same value: ""
           0.24900     0.00000     ...Session State: Save "ROWS_PER_PAGE" - saving same value: ""
           0.26500     0.01500     ...Session State: Save "P0_CLEAR_WS" - saving same value: ""
           0.26500     0.00000     ...Session State: Saved Item "RENDER_REQUEST" New Value=""

      I can't figure out why the item is being set to null.

      This problem also does not occur on every page. The pages in question are a multi-step "wizard" that allows the user to navigate between steps with "Next" and "Previous" buttons. Since this is a page 0 item, it appears on every page in the wizard so I'd expect it to behave the same. When you open the wizard at step 1 and press next to go to step 2, the item (RENDER_REQUEST) is set correctly on step 2 of the wizard, BUT when you then click Next to go to step 3, RENDER_REQUEST is null on step 3. If you open the wizard at step 2 and press Next, RENDER_REQUEST is null on step 3.

      I did find a work around, but it doesn't make any sense why it would work: if I move the RENDER_REQUEST item from the "Footer Items" region to a page level item (by using Edit All and setting its region to blank), then the problem goes away. If I move it back to the "Footer Items" region the problem reoccurs.

      I am working on Application Express on Oracle Database 11g Enterprise Edition Release

      Any help would be greatly appreciated!

      Thank you.