MeanMike Posted August 1, 2008 Posted August 1, 2008 Hello all, Please forgive me as its been awhile since I've worked in FMP and I'm sure I'm just a little rusty. So here is the problem I three tables lets call them A,B,C table A has a field called ID containing a string table B has three fields ID which is related to table A's ID and a field COUNT which is a calculation field that contains count(A:ID) resulting in a the number of records in A that contain the ID. MyBOOLEAN_A which is a calculation that checks to see if count is greater than 10(as an example) table C contains 1 field MyBOOLEAN_B set to 1 or true and related to table B and I have a portal showing the data related. Sounds good right ? but the records don't show up in the portal because MyBoolean_A is not indexed. but no matter what I do I can't get it to index. I keep getting a message saying the field cannot be indexed because it references a related field, an unstored calculation field.... blah blah any help or suggestions would be appreciated mm
mr_vodka Posted August 1, 2008 Posted August 1, 2008 First when referencing a related field it will not index the field. The parent side of a relationship can have an unidexed field, but the child side must be indexed. You will have to try to reapproach your method and adjust the parent side.
bcooney Posted August 1, 2008 Posted August 1, 2008 John is correct, but I'm finding it difficult to follow your scenario. Can you use the actual table names and tell us your requirements? You mention needing to know how many records in TableB contain the foreign key for TableA. Do you need this in browse mode, or can you run a subsummary report? More details.
MeanMike Posted August 1, 2008 Author Posted August 1, 2008 the Parent in this case would be table C since it has the portal ? mm
MeanMike Posted August 1, 2008 Author Posted August 1, 2008 ok let me start over then I'm trying to track software. So I have three tables. InUSE,Software,Hardware InUSE contains two fields SoftwareID,HardwareID Software contains many details about the software but the man focus is is the fields SoftwareID NumLicenses NumInUse(this is where I count the number licenses for this software that are in use) and HaveLicense a calculation if(NumInUse < NumLicenses; True ; False ) then In Hardware I made a field called HaveLicense and set it to true then made the portal showing the details of available software. does that make more sense ? MM
comment Posted August 1, 2008 Posted August 1, 2008 Try making your calc = Case ( NumInUse < NumLicenses ; SoftwareID ) then define a new relationship between Software and Hardware using the "x" operator, and change the calc field in Hardware to = List ( AllSoftware::cAvailableID ) This field can be the match to a third occurrence of Software, to show only available records. Note that as always with relationships depending on other relationships, you can expect some refresh issues - Refresh Window [ Flush cached join results] often comes handy in these situations.
MeanMike Posted August 1, 2008 Author Posted August 1, 2008 I figured out what you meant thanks you very much that worked
Recommended Posts
This topic is 6017 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 accountSign in
Already have an account? Sign in here.
Sign In Now