1 2 Previous Next 17 Replies Latest reply on May 30, 2013 1:00 AM by Fred(CH)

    Upper( text )  Randomly works

    jacksrmd

      Summary

      Upper( text )  Randomly works

      Product

      FileMaker Pro

      Version

      12.0v4

      Operating system version

      Windox Xp   sp3

      Description of the issue

      Upper (text) randomly works.  Some fields are calculated in uppercase and some are as typed.

      Steps to reproduce the problem

      Create calculation field, LastName_Upper:

      Upper (LastName)

      Text result is text.  Calculation result is unstored.

      Expected result

      All LastName_Upper fields in UPPERCASE.

      Actual result

      Some LastName_Upper fields in UPPERCASE.

      Some LastName_Upper fields in Title case (as originally typed)

      Exact text of any error message(s) that appear

      N/A

      Workaround

      N/A

        • 1. Re: Upper( text )  Randomly works
          Fred(CH)

               Hi John,

               Very strange... Just to clarify, when you said randomly, is that meaning that depends on record or that depend on layout ?

               Because the only way i can replicate this behavior is when my object layout is defined with a text style like Title Case that overwrap the calculation...

               I use a Mac but i don't think this calculation bug can be system-specific.

               Let us know...

               Bye, Fred 

          • 2. Re: Upper( text )  Randomly works
            jacksrmd

                  Randomly depending on the record.

                 1st thing I thought was layout - field format, but No --   the field is formatted as Plain Text.

            • 3. Re: Upper( text )  Randomly works
              Fred(CH)

                   Hi John,

                   Thank you for your answer.

                   Assuming the formula is in extenso :

              Upper ( LastName )

                   Can you tell us if is there an auto-enter formula on the referred field, i mean LastName, and if true, what is this formula ?

                   Thank you for your patience...

                   Bye, Fred

              • 4. Re: Upper( text )  Randomly works
                jacksrmd

                      LastName is a text field.

                     Thank you for helping me...

                • 5. Re: Upper( text )  Randomly works
                  Fred(CH)

                       Thanks John.

                       But a text field can also have a formula here :

                       Select the field and then press Options… button.

                       Then, in auto-enter tab you can also define a calculation.

                       Could you please check that ?

                       Bye, Fred

                  • 6. Re: Upper( text )  Randomly works
                    Fred(CH)

                         Sorry but i have a better idea :

                         If you complete a bit the formula on the unstored calculation like this :

                    Upper ( TextFormatRemove ( LastName ) )

                         Instead of only :

                    Upper ( LastName )

                         What's happen ?

                         Bye, Fred

                    • 7. Re: Upper( text )  Randomly works
                      philmodjunk

                           What I think Fred is getting at with the auto-enter calc questions is that auto-entered calculations may not update the contents of the field automatically in a few situations, producing seemingly random results.

                           If you have a field of type calculation with a result type of text, it should update automatically and this would be a better test of whether there are issues with the Upper function.

                           Circumstances where an auto-entered calculation may fail to update:

                             
                      1.           If the "do not replace existing value.." check box is selected. (That's obvious, but we have to rule out the obvious too)
                      2.      
                      3.           If the referenced field is from a different table, changes to the data in that field will not cause this field to update.
                      4.      
                      5.           If you have data already in the field before you define or change the auto-enter calculation, the data in existing fields will not update, the added or modified calculation will only affect what is seen in new records or after changes to a field referenced in the field "triggers" a recalculation of the field's value.

                            

                           If 3. is a possibility here, see this thread: Updating values in auto-enter calc fields without using Replace Field Contents

                      • 8. Re: Upper( text )  Randomly works
                        jacksrmd

                              Text field without any calculations  (auto-calc or otherwise).

                             I'll try to use the  

                        Upper ( TextFormatRemove ( LastName ) )

                             Thanks Fred & Phil

                        • 9. Re: Upper( text )  Randomly works
                          philmodjunk
                               

                                     Text field without any calculations  (auto-calc or otherwise).

                               Sorry, but that makes no sense. If there are no calculations, then there is no use of the Upper function--as that is a calcualtion.

                               If you are selecting the upper STYLE via the format menu, there are definitely reasons why some fields show this and others do not.

                          • 10. Re: Upper( text )  Randomly works
                            Fred(CH)

                                 Hi Phil,

                                 Sorry but it is probably my fault : my question was confusing and you are not talking about the same calculation with John.

                                 There are two fields implied : the text field and the unstored calculation field.

                                 My speculation was :

                                 The text field "LastName" had, at a time, an auto-enter calculation defined with a formula like this : TextStyleAdd ( Self ; TitleCase ). Since, this auto-enter calculation has been cleared. But all the records before this modification still contain the style TitleCase.

                                 Thus, the unstored calculation Upper ( LastName ) seem to be randomly dysfonctionnal.

                                 Bye, Fred

                            PS : Speculations, i know, sorry. Another way was to display the result on Data Viewer with FMPA.

                            • 11. Re: Upper( text )  Randomly works
                              jacksrmd

                                    Sorry for the confusion Phil.

                                   Thanks for the explanation and assistance Fred.  :)

                                   I haven't tried the Upper (TextFormatRemove (LastName) ) calculation yet.

                              • 12. Re: Upper( text )  Randomly works
                                philmodjunk

                                     Fred and I are on the same page. Data formatting of specific data in a field--either pasted with the text from another source or applied by selecting the text and formatting it from the Formatting tool bar, will supercede formatting applied via calculation or layout level formatting and this can produce a situation where you see the correct format in one record and not in another.

                                     The TextFormatRemove function is a major problem solver for such issues.

                                • 13. Re: Upper( text )  Randomly works
                                  Fred(CH)

                                       Yep !

                                       And the potential confusion between Upper ( LastName ) and TextStyleAdd ( LastName ; Uppercase ) add a little bit of spice on it.

                                  Note for the beginners : The first one is processing on data-level and the second only on formatting level.

                                       Bye, Fred

                                  • 14. Re: Upper( text )  Randomly works
                                    jacksrmd

                                          I finally got around to applying

                                    Upper ( TextFormatRemove ( LastName ) )

                                         It worked like a CHARM!!!!

                                         Thanks Fred.

                                    1 2 Previous Next