4
votes

I am currently working in Oracle APEX version 5.1.2. I have created an interactive grid in my application that queries data from a table stored in the Oracle database. The data being queried is just several different URLs that refer to different pages in my application. So in other words, in each cell of one of the columns in the interactive grid there is a URL.

Then on a different page in the same application, I have created an interactive report that queries all of the data from the interactive grid. One of the columns in that interactive report is set to type "Link" and the link attribute is set to #LINK#. So each cell in that column contains a hyperlink for one of the URLs stored in the interactive grid.

The problem is that when I click on the hyperlink, I lose my session state and and am redirected to the login page. When I do then login, I am directed to the page in the application that the link was supposed to direct me to. The link only works if I hard code my current session ID in the URL in the database. But I'm trying to find a suitable substitution string for the session ID so that I don't have to hard code the session ID. I have tried the substitution strings &SESSION. and :APP_SESSION and &APP_SESSION. and V('SESSION') and nothing has worked.

Does anyone have any ideas of how to achieve this so that I don't lose my session state?

Thank you in advance.

Update:

enter image description here

enter image description here

1
How does the URL look like? Could you post it? Mask server name, if necessary. Should be something like http://apex.oracle.com/pls/apex/f?p=11563:1:&SESSION. (ampersand SESSION dot; I believe you did that already, did you not? If so, huh, it just should work ...).Littlefoot
http://###.##.#.##:###/ords/f?p=60003:21:&SESSION. -- sorry I don't know how else to mask part of the URL. Wherever I put a pound sign there is a number there in the actual URLKatherine Reed
That's OK, no problem. So, yes - you did use &SESSION. and it still forces you to log on ... hm.Littlefoot
Yes. It works if I create a hyperlink that doesn't refer to a URL stored in a table in the database. For example, if on a completely separate page I create a region of type "Static Content" and in the "Source Text" box I write some HTML like <a href="http://###.##.#.##:###/ords/f?p=60003:21:&SESSION."> then it works perfectly. I click on the hyperlink and it goes directly to page 21. I think the problem is that I am referring to URLs stored in a database, but I don't know how to fix the problem.Katherine Reed

1 Answers

3
votes

Apparently there is no problem with the url formed.

Could you inspect the element and display the generated html on the page?

I think you should not fill in the "link attributes" field, it should be blank. Click "Target" and there put the value #LINK# in the "URL" field. enter image description here

enter image description here