Subject Re: [IBO] cascade relations
Author Paul Vinkenoog
Hi Gediminas,

> when trying to scroll Dances LisbBox, got exception "Dataset cannot
> scroll".

What kind of ListBox? Do you have a TIB_LookupList there, or something
else? Don't use an IB_Listbox! That's not for lookup datasets but for
fixed lookup values. (If your Dances don't change often, you could take
that approach but it would change the whole KeySource-Lookup part of
the story!)

Please try it with a TIB_LookupList like I explained in part 3 of my
other post.

> I suspect, that KeyLinks & KeySource fields must be set not in
> qryDancesLookup, but in the qryClassDancesDet.

No: KeySource, KeyLinks and KeyDescSource are all set in the Lookup
set. Just as MasterSource and MasterLinks (and possibly MasterParam-
Links) are all set in the Detail set.

To put it otherwise: you set up a Master dataset as if it doesn't know
about the Detail set. And you set up a KeySource dataset as if it
doesn't know about the Lookup set. All links are made from within the
Detail set (in an MD relation) and the Lookup set (in KS-LU).

> Am I right, that lookup dataset is parent?

Actually KeySource-Lookup is not a clear Child-Parent relation. But if
you want to see it that way, the KeySource is parent (the set you
really want to work with) and the Lookup is child (a little helper
where you look up values to insert into the "important" set).

> Thank's for such detailed answer - really helpful. GSG would be
> great, but it is not affordable :)

Too bad. How about robbing a bank? :-)


Greetings,
Paul Vinkenoog


DISCLAIMER
I don't _really_ want you to rob a bank. If you still decide to do
so, I'm in no way responsible!