Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Applications > FileMaker: limiting portal rows returned from Find

FileMaker: limiting portal rows returned from Find
Thread Tools
schwa
Mac Enthusiast
Join Date: Oct 1999
Location: Brooklyn, NY, USA
Status: Offline
Reply With Quote
Dec 20, 2002, 02:49 PM
 
FileMaker gurus-

I've got a FileMaker db that uses a portal to another db to show the salary history of an employee. If I do a Find using the portal fields (e.g. anyone with a salary over X, or anyone who got a raise in 2002), it returns matching records in the master db, but it returns *all* related portal rows for that master record, not just the relevant ones.

For example, if my record has three salary history entries: $50k on 1/1/01, $60k on 1/1/02, and $70k on 1/1/03, and I run a search to see what everyone was earning in 2002, I only want to see the $60k record. FileMaker will return my master record (since I have a matching portal row), but show all three portal rows.

Any advice?
     
kennedy
Mac Elite
Join Date: Jul 2000
Location: Dallas, TX, USA
Status: Offline
Reply With Quote
Dec 29, 2002, 10:32 PM
 
take your question to fmforums.com ... you'll get a good answer there.
     
chadbert
Fresh-Faced Recruit
Join Date: Aug 2002
Status: Offline
Reply With Quote
Dec 31, 2002, 10:15 AM
 
That's expected and desirable behavior; technically, you're searching for employees, not salary histories, and once the matching employees are found you get all of their data, including all related records.

There's no way to do what you want as part of a search, exactly, but you can create filtering portals. You'll need to create a global field in your parent (employee) file to indicate the year you want to see, and calculated keys in both files (in the employee file, concatenate the global and the employee id, in the salary history file do the same for the salary year and the employee id) and base your relationship on those calculated fields. There's additional steps to make it possible to still see multiple years in the portal. Try databasepros.com for downloadable examples.
     
   
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 12:17 PM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,