I'm wondering what would be the best strategy (and alternatives) to populate a 
control with data from a many-2-many relation.

Here's the setup (You can find this Demo In Progress in the Wiki under "Demos 
in Progress":
book.book_id (table.table_pk)
bookauthor (link table, fields: bookauthor_id, book_id, author_id)
author.author_id (table.table_pk)


Objective:
Populate a dListBox in a form where the primary bizobj datasource is book. 
Everytime one changes book the dListBox gets populated with the name of the 
related authors. I've read the WikiPage "How To Populate and Use List Controls" 
but I can't get much from it for this particular cross-table dynamic context.

1 - My feeling is that dabo can take care of this for me (is this true?).

Do I accomplish this by chaining bizobjs? I mean make bookBizobj parent of 
BookAuthorBizobj and BookAuthorBizobj parent of RelatedAuthorBizobj! I've tryed 
this approach without any complaints from Dabo (no exceptions raised), but I'm 
unable to figure out to populate the dListBox. The code in the WikiPage 
reflects these changes.

My difficulty comes from the fact that I have to bizobjs with the same 
DataSource.
  * AuthorBizobj - used to populate the Authors Grid on page two (working like 
a charm - txs guys ;-)
  * relatedAuthorBizobj - to be used to populate the dListBox (as per above)


2 - If dabo can't do this for me what would be the soundest approach?
  * Should bizobjs be used?

BTW: Is there a way to get a bizobj or a dataset with fields from two tables?

Txs for any pointers,
Miguel


_______________________________________________________________________________________
Aqueca o seu Inverno com o credito pronto a usar!
Saiba mais em http://www.iol.pt/correio/rodape.php?dst=0701181



_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/dabo-users/[EMAIL PROTECTED]

Reply via email to