Search code examples
oracle-databaseoracle-apex

How Current List Entry in Oracle Apex works?


I have an app with page. In a page there is an item that I use in query. So in Menu Entry I set Target = my page with item value (e.g. :P1_TYPE = 1). I have 3 menu entry that refers to one page but setting :P1_TYPE = 1 or 2 or 3. Everything works fine, but in side navigation menu active tab always first. I see "Current List Entry" in "List Entry" but don't understand how it works. I tried sql queries, pl/sql expressions that return :P1_TYPE = (1 | 2 | 3) but it doesn't work anyway. List Entry edit page


Solution

  • In your case I would use the "Expression > pl/sql" option with condition

    :P1_TYPE = '1'
    

    for the first menu entry (where you're setting P1_TYPE to value 1 in the url), for the other pages use 2 and 3

    Here is how I tested it on my local env:

    enter image description here

    --UPDATED--

    Note that if you have tabs pointing to a different pages then it might be needed to included the page number in the expression. For example in the source above the value for P1_TYPE might exist in cache and cause the condition to yield true when the user is on page 2. It is safer to do the following:

    :P1_TYPE = 1 AND :APP_PAGE_ID = 1