2 Replies Latest reply on Jun 7, 2011 1:40 PM by philmodjunk

    Calculation field cannot be modified: "the specified field cannot be found"

    rgi

      Title

      Calculation field cannot be modified: "the specified field cannot be found"

      Post

      I have inherited a Filemaker database that has been updated from v4 and has had a couple of developer hands on it.  The database functions well in FM11, and we want to add two fields to job budgeting. There is a calculation field that compares hours entered to hours budgeted to identify when a job is approaching or over budget in given areas. However, I can't modify that calc field at all; in fact, opening and pressing ok without making any change generates the same error: "the specified field cannot be found". Everything is working as it should, but frankly this level of calculation is beyond my understanding of Filemaker calculations. You can see in the screen shot what field is being identified.  Here is the text of the calculation as well:

      If(GetRepetition ( FLAG ignore budget;2)=1;"";Budg Prod+Budg Comps+Budg Copywriter-Sum(${Job.Time{Production}}::C hours))

      Thanks in advance for any direction.

      Screen_shot_2011-06-07_at_3.41.03_PM.png

        • 1. Re: Calculation field cannot be modified: "the specified field cannot be found"
          aammondd

          Looks like a syntax issue identifying the field via a variable. i think the brackets are adding confusion and are either in the wrong place or are not needed at all. Typically a calculation only uses perenthecies as its groupings. If its simply a calculation field then the variable "$" wouldnt be present either.

          Should look something like this ...-Sum(Job.Time Production::C Hours)) though the table name Job.Time Production seems odd to me too but apparently it would work.

           

          • 2. Re: Calculation field cannot be modified: "the specified field cannot be found"
            philmodjunk

            This part of the expression looks odd: ${Job.Time{Production}}::C hours

            First, make sure that you have a field named C hours in the table to which the Job.Time{production} table occurrence refers.

            The first set of {} and the $ are how FileMaker resolves references to table occurrence or field names that include characters that would otherwise be evaluated as operators in the expression.

            I think FileMaker is having trouble with that extra set of {} here.

            Personnally, I avoid using operator symbols and brackets like these in table occurrence and field names as they make calculations hard to read and can make indirect references to them much less flexible.

            You might want to open a copy of this file and try renaming this table occurrence to remove the {}, then edit the calculation to see if you now can edit the expression. (May have to respecify the c hours field in this expression when you do.) If that works, test your modified copy of your file carefully or search a database design report for references to this table occurrence to make sure that your name change hasn't broken another part of the system even as it, hopefully, fixes this calculation.