I am fairly new to Oracle Apex, and have a problem. Our application currently has a method of entering data, with several text boxes and Optional List of Values. I would like to have an LOV based on information in another text box like so:

```
select APPOINTMENT_ID PATIENT_ID from APPOINTMENT where PATIENT_ID = :P9_PAT_NUM

```

where P9\_PAT\_NUM is a patient number in a text box. However, this would apparently only work if the text box has already been submitted, else it assumes the text box is null.

Is there any way to get this working with an LOV, or perhaps some other method?