4 Replies Latest reply on Feb 28, 2011 7:50 AM by kingsley47

    Left (Text;number) Function



      Left (Text;number) Function


      I have made a field that should return the last four text from another field.

      It basically looks like this...

      Field 2 = left(Field 1;4)

      Now the only issue I'm having is that Field 2 won't populate unless I go in and recommit some of the values in Field 1. So for field 2 to show anything I basically have to go into field 1 and erase the last letter, retype it and then click out of the box. I have over 4500 records that I need this calculation to work for. So recommitting field 1 in every record is not really an option. Could someone help me figure out a way around this? So that field 2 automatically pops up?

        • 1. Re: Left (Text;number) Function

          It is a calulation field, and not a text field, with that calculation as auto-entered?

          • 2. Re: Left (Text;number) Function

            Yes, I did have it set as a text. Once I changed the field type, it worked. Thanks alot.

            Also, I realize that I put left(Field 1;4) when I actually meant right(Field 1;4).

            One more thing....

            I have a similar issue that has been occurring with lookup values. I have a number of fields that will autmatically populate based on the information put into various other fields. I actually have it set up so that you should really only have to type into one field and then the rest of the information will fill itself out. (Assuming the data being pulled has been put into the correct places in other FMP databases.) Most of my look up fields work but I am having issues with one set of fields that are lookups and are dependent on a specific field called Material Specification. The mat'l spec. field itself is a lookup field based on a field called USB#. The material spec. field populates correctly but the other fields that are dependent on that one do not always autmatically pop up. I basically have to go through the process of recommitting the material specification field and then the other dependent fields will populate themselves. To make matters a little more complicated, this doesn't happene every time. It only happens when certain specifications are referenced in the material specification field. The only thing I can think of is that it has something to do with when the material specification records ( a different related database) were created. Some of the records were made before I had made a relationship between the two databases and some were made after. I have tried copying the material spec. record and then deleting the original (basically making it so that the record was now made after I had set up the relationship between the two databses) but that didn't fix the problem either. If someone could point me int he right direction on this one as well I would really appreciate it.

            • 3. Re: Left (Text;number) Function


              I have made a field that should return the last four text from another field.

              It basically looks like this...

              Field 2 = left(Field 1;4)"

              That calculation gets the FIRST four letters of Field 1.

              Set the Field 2 as calculation, result text. You'll see all Field 2 calculated.

              Then if you need it, set field 2 as text with autoenter calculation (same formula). 

              (sorry about my english, hope you understand me)

              • 4. Re: Left (Text;number) Function

                Thanks, Juan. Once I switched up the field type it worked. Also, yeadh I had the side backwards.