Skip to Main Content

APEX

Announcement

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!

BUG: APEX 20.1.0.00.13: Display Image items do not work with "Per Request" session state key items

fac586Jun 4 2020 — edited Aug 31 2020

Images are not rendered for Display Image items where the item Based On attribute is BLOB Column returned by SQL statement and the SQL statement references a value from a page item with a Maintain Session State property set to Per Request (Memory Only).

In this demo two dialog pages can be called using buttons in each row of an interactive report. The dialog pages both contain a standard Form region based on the PHOTOS table, and are identical except for the Maintain Session State properties used on their page items. On page 307 (the "Per Request Form") all items use Per Request (Memory Only) whilst on page 308 ("Per Session Form") all items use Per Session (Disk).

On both pages the first four items are Display Only items containing the PHOTO_ID primary key value. The first is the P30X_PHOTO_ID PK item value set in the IR link URL. The next three items are Display Only items that successfully clone the PHOTO_ID value using three different methods that reference P30X_PHOTO_ID item value from session state.

  • Display Only item based on Item Value: source Type is Item; source Item is P30X_PHOTO_ID.
  • Display Only item based on Item Value: source Type is SQL Query; SQL is select photo_id from photos where photo_id = :p30x_photo_id.
  • Display Only item based on Output of PL/SQL Code: htp.prn(:p30x_photo_id);

This all works as expected. However, when the P30X_PHOTO_ID item value is referenced in a similar way for a Display Image item based on a BLOB Column returned by SQL statement:

  • Display Image item based on BLOB Column returned by SQL statement: SQL is select photo_blob from photos where photo_id = :p30x_photo_id

The results are different. On page 307—where P307_PHOTO_ID session state is Per Request (Memory Only)—no image is returned. On page 308—P308_PHOTO_ID session state is Per Session (Disk)—the expected image is shown.

Since none of the Display Only items (even the obscure Output of PL/SQL Code option) have any trouble retrieving the Per Request (Memory Only) value during page show processing, I see no reason why a similar usage should not be supported by the Display Image item, and that this is therefore a bug.

Comments
Post Details
Added on Jun 4 2020
2 comments
1,396 views