Hi guys, I hope some one can help me solving this problem!
I have two select list (drop down). The first one is to choose between 2 "visit type" (Standard or Non-Standard), the second one is to choose a "location". The list of "locations" in the second select list is determined by which "visit type" chosen in the first select list. I tried implementing the second select list values as "PL/SQL Function Body Returning SQL Query" like this:
DECLARE
query varchar2(255);
BEGIN
query := 'SELECT Location_Name AS "d", Location_Name AS "r" FROM Table_Locations';
IF :P4_VISIT_TYPE = 'Standard DC Facility Tour' THEN
RETURN query || ' WHERE Is_Standard = 1';
ELSE
RETURN query;
END IF;
END;
The problem is, this will not work if P4_VISIT_TYPE value not set. At the P4_VISIT_TYPE's "Page Action on Selection" attribute, it seems there is no option available to set the select list value without redirecting? I want to avoid redirect because I do not want the user to re-type other fields again after the redirect.
EDIT:
I also have tried looking at Dynamic Action, but I think it does not provide something like "Set List of Values for this item" feature?
P.S. I am using Apex v5.0.3
Danny