Skip to Main Content

Oracle Forms

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

"More" LOV Selection Conditions

MarkFoldenNov 6 2008 — edited Nov 10 2008
The following Trigger ("thanks" to Francois) eliminates previously selected questions from appearing in a LOV when selecting it again (in the case of multiple record items).

How can I eliminate previously selected items in the record group from appearing in the LOV "AFTER" the data has been posted (i.e. committed to the database)? In other words, this works great the first time the User enters the data but only eliminates elements of the record group from the LOV for the current session of the form. If the user re-enters the form at a later date to edit or change the data, I don't want the previously selected questions to be options to choose from on the LOV.

Ideas... suggestions? Thanks, M



-- Remove the selected value from Record Group to eliminate duplicate selection
DECLARE
rg_id RecordGroup;
rec_count NUMBER;


BEGIN

-- Get the record group ID
rg_id := Find_Group ( 'RG_SEC_Q' ); -- returns a record group ID when it finds a valid group with the given name


-- Get the number of rows --
rec_count := Get_Group_Row_Count( rg_id ); -- Returns the number of rows in the record group


-- Delete the selected row --
FOR loop_counter IN 1..rec_count LOOP
If Get_Group_Number_Cell( 'RG_SEC_Q.LOOKUP_VALUE_DESC', loop_counter ) = :AGENT_SEC_QUESTIONS.SECURITY_QUESTION_DETAIL THEN
Delete_Group_Row( rg_id, loop_counter ); -- Returns the number value for a record group cell identified by the given row and column and then deletes the indicated row of the record group
exit ;
End if ;
END LOOP;

END
This post has been answered by François Degrelle on Nov 6 2008
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 8 2008
Added on Nov 6 2008
7 comments
532 views