Search 'master' table by child attributes?

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
mvwmvw
User
Posts: 16

Search 'master' table by child attributes?

Post by mvwmvw »

Say I have a 'master-child' relationship between two tables and that one attribute of the 'child' table is 'color'. How can I set things up so the user can easily search to find all 'master' records for which any child record has a color of 'green'? This may be blindlingly obvious to others but it's befuddling me today. I realize I could create a view and have them search the view, but I'd like to keep the interface as simple as possible for whatever kind of adds, edits and searches the users want to do. Creating a view, and a menu item for a view, just for searching is thus undesirable.

Any advice would be most welcome.

= Mike =


mobhar
User
Posts: 11734

Post by mobhar »

If you don't want to obviously create the separated View for searching, then do not use "Master/Detail" mode for searching records. Just use the desired single detail table to search the color "green", so that the result should return all the detail records that contain the master field in it.

Note that there is always the advantage and the disadvantage when you want to keep the interface as simple as possible for that case.


mvwmvw
User
Posts: 16

Post by mvwmvw »

Mobhar,

Thanks for your reply on this. I'm acutely aware of the trade-offs here -- and really like how PHPMaker handles the whole master-detail area in general -- I just hoping I was missing something obvious. (Sigh)

= M =


Post Reply