Dependent LOV - invalid number error
312597Jun 28 2007 — edited Jun 28 2007APEX 3.0, RDBMS 9.2.0.4
I have four items in a form each calling a LOV. The second, third and fourth LOVs are cascading, dependent LOVs.
The first LOV is named IS GROUP, displays a description and return a number (id). The first item in my region calls the IS GROUP LOV. The attribute, “Display As” is set to “Select List with Submit”. In the list of values section of the first item, the “Null Display Value” is a literal: -- Select a Group --
The second LOV is named SUBJECT TYPE, displays a description and return a number (id). The second item in my region calls the SUBJECT TYPE LOV. The attribute, “Display As” is set to “Select List with Submit”. In the list of values section of the second item, the “Null Display Value” is a literal: -- Select a Subject --
As a dependent LOV, the second LOV is dependent on the user’s response to the first LOV. The SUBJECT TYPE LOV query uses the number (id) returned from the IS GROUP LOV to generate the second LOV select list.
When the page is first rendered, the following error occurs:
Error: ORA-01722: invalid number performing List of Values query: "select subject_type_descr d, subject_type_id r from docit_subject_type where is_group_id = :p1_is_group_id order by subject_type_descr ".
The issue (assumption) is that the bind variable :P1_IS_GROUP_ID has not yet been populated by the user in the first LOV. As soon as the user selects a valid value from the first select list, the error goes away and my second select list item is populated.
Assume there must be some setting to NOT make the second LOV “active” until the first LOV has rendered a result. I played around with conditional section of the second item, but no soap.
Any advise, recommendations and/or thoughts are appreciated.
Thanks,
Barry