Let me start explaining the system design.
There are Items that can be supplied by multiple Vendors. There is a BO for both of these plus a BO called VendorItems that is related to both of these tables (and it also has additional info, like pricing, delivery dates, etc.) Some Items can be supplied by multiple Vendors
All is good with these 3 BOS. Here is where I am scratching my head. There are 2 other BOs, OrderHeader and OrderLine. The OrderHeader has a peer relationship to Vendors. (There is only one Vendor for for each Order Header). The OrderLine has a peer relationship to Items.
I need a filter on the Items Relationship in the OrderLines so that will ONLY show the items that are for the Vendor that is in the OrderHeader. In other words, if the OrderHeader is related to ACME Vendor, and there are 5 records in the VendorItems for ACME, when I am entering OrderLines, I want to only see these 5 items to choose from.
Any suggestions for the custom query for the filter? Or have I confused everyone?
Thanks
Bruce