Re: Problems in olsqlforms30 and OCI (in C)
Date: 7 Sep 92 11:51:56 CST
Message-ID: <1992Sep7.115156.1307_at_hermes.dlogics.com>
In article <1992Sep3.163521.26698_at_cbfsb.cb.att.com>,
colten_at_cbnewsb.cb.att.com (marc.colten) writes:
> [...]
>
> 3) Can you do a query on a detail block and have the relevant
> information come up in the master block? It works fine
> the other way. I do a query in a master block and it brings
> up two records in the detail (which it should). I've tried
> doing the reverse and it won't work.
>
> Is this possible?
>
It is possible, but in very limited conditions. The limitation is that you must
have only one master corresponding to the set of retrieved detail rows. If you
query the detail on some non-key attribute, you will retrieve rows which may
correspond to several different masters. In this case, which master shall you
display? You might say, "all of them", but there is no key-enforcement
mechanism in sqlforms that can do that; to query the master as if it were a
detail, you will need just ONE key to enforce.
If this limitation is okay with you, then just write triggers that treat
KEY-ENTQRY and KEY-EXEQRY in the detail exactly as if they are in the master,
but with the block associations reversed. Sqlforms will not generate this
relationship in the default-block display.
>
> 4) Can you do a LOV on a block, or failing that on a non-enterable
> field? I just want a list relevant to the data I've queried
> as an alternative to a second page, which is not really necessary
> and really slows things down.
>
You can write KEY-LISTVAL triggers at form, block, or field level. Write a
pop-up block that displays the info you want. Make the key-trigger go to that
block and execute your query. The "<list>" tag will not display on the message
line since you will not be using the built-in list-of-values hook. But you will
have much more flexibility.
-- Dave Mausner, Senior Consultant / Datalogics Inc / Chicago IL / 312-266-4450 dlm_at_dlogics.com Motto: Just show me the codeReceived on Mon Sep 07 1992 - 19:51:56 CEST