Developer/2000 - FORMS Help

From: Matthew Faso <faso_at_slip.net>
Date: 1997/08/29
Message-ID: <5u6u96$1ck$1_at_owl.slip.net>#1/1


I need some help with Developer/2000 (FORMS 4.5). I've found various ways to do what I want to do, but I'm not sure of the best way. The problem boils down to the following:

I have a view containing people (actually there not people, but it will be simpler this way). The key is person_id. Each row in the view also has a parent_id and a child_type (Boy or Girl).

FAMILY_VIEW
person_id
parent_id

child_type
a bunch of other stuff

I want to create a form like the following:

PARENT_BLOCK (1 record)

BOY_BLOCK (multiple records)

GIRL_BLOCK (multiple records)

I want the user to be able to query a single parent in the PARENT_BLOCK (by person_id). When the query is executed all 3 blocks should be queried. I don't need any of the blocks to be updateable, I just need a query of the PARENT_BLOCK to force the BOY_BLOCK and GIRL_BLOCK to be queried with the following criteria:

parent_id = :PARENT_BLOCK.PERSON_ID and child_type = 'BOY'

or

parent_id = :PARENT_BLOCK.PERSON_ID and child_type = 'GIRL'

Also I need to be able to click a button and refresh all 3 blocks for the same parent_id (that was previously queried).

Thus, the user can query the PARENT_BLOCK only, the other two blocks should be queried automatically. A button click should re-query all three blocks for the currently selected parent. Finally, I don't want any annoying 'Query returned no rows' errors if there are no boys or girls for the selected parent.

Basically, I've tried with relations, but it seems like kind of a kluge for my situation. Currently I have KEY-ENTQRY and PRE-QUERY triggers on the BOY_BLOCK and GIRL_BLOCK that prevent the user from going into QUERY-MODE and set the query criteria from the PARENT_BLOCK. However, I get a FRM error if no Boys or Girls are returned and I can't get Refresh button to work properly.

Thanks for any assistance,
Matt Received on Fri Aug 29 1997 - 00:00:00 CEST

Original text of this message