Jump to content

listing relations in a repeating field


Jon Thompson
 Share

This topic is 6513 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies

I have a database I a rewriting in v7, which is allowing me to eliminate many intermediate databases and scripts due to the ability to do less than/greater than relationships.

However, I have a many to many complex relationship to the class database (eligible classes) that I want to invalidate the user if their record is in another many to many database (enrolled classes). The way I was thinking of doing this is to place a record for each studentID that is in enrolled classes into a repeating field in the class database, then adding another line to the eligible classes relation that eliminates that class if the student is listed. I would like to do this on the fly, but if I need to do it when I add/remove the student from the class, it would be acceptable.

Oh how I wish that FM could define a relationship based on the data in another relationship. Then this could be simple.

Version: v7.x

Platform: Mac OS X Panther

Link to comment
Share on other sites

Repeating fields do not work correctly in relationships. Only the first repetition is related.

I'll echo many folks' advice here: don't use repeating fields. They are a remnant of FileMaker from before it was relational. They have very limited use in today's versions.

Link to comment
Share on other sites

  • Newbies

actually, in 7, repeating fields are _all_ relational.

I figured out my solution. First I created a layout with the repeating field, then upon adding a student to the class, I entered their studentID into the roster using a script that loops through the repeating fields. Finally I added a relation item that removes the individual if they are listed in the roster.

Not as clean as a SQL database would have been, but I suppose it will do.

On a side note: It appears that FMP7 automagically freezes the window if you go to a layout and return to the original layout without allowing the user to enter information.

Link to comment
Share on other sites

Listen to Sam. Forget the repeats. This isn't even good practice for a Filemaker 3 database, let alone Filemaker 7. You can't report on repeats, you can't select on them, etc. They have their uses, but this isn't one of them.

Link to comment
Share on other sites

It's twelve months (or more) down the track when you can't work out how to get a particular report to work... that's when you realise it's been done wrong.

Link to comment
Share on other sites

This topic is 6513 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.