5 Replies Latest reply on Jun 27, 2013 12:08 PM by philmodjunk

    Find/Replace produces blank dialog when data loaded from file does not match field requirements

    nspies

      Summary

      Find/Replace produces blank dialog when data loaded from file does not match field requirements

      Product

      FileMaker Pro

      Version

      12 Advanced V12.04v

      Operating system version

      OS X 10.9(13A476u)

      Description of the issue

      Whilst doing a Find/Replace operation to remove a symbol representing null data (i.e. leaving such fields empty) a modal dialog _without message text_ but with 'Revert Data', 'No' and 'Yes' buttons can be produced if a field defined a needing data results in having no data due to the Find/Replace.

      Steps to reproduce the problem

      Define a file with some fields required to have data and others do not. Devise a tab-delimited text file with some fields containing a text symbol to represent null data and place this symbol in both required-data and non-required-data fields.

      Use Find/Replace to produce the empty null data fields from the symbol used to represent null in the data file.

      Expected result

      The Find/Replace operation to remove the symbol representing null data is removed, and the data resides within the database without problem, meeting the definitions of each field. (This happened with 11 out of 12 files in my case.)

      Actual result

      If the result of such a Find/Replace operation produces a null field that requires data, it complains, as it should.

      However, the modal dialog it puts up should have descriptive text to permit a rational choice of actions from the three choices available.

      Exact text of any error message(s) that appear

      [See screen shot]

      Configuration information

      The original, untouched data file was defective in that there was null data despite the fact that the field was defined as having to have data.

      Workaround

      I put a space in place of the null data, and used Find/Replace to put null data where it belonged in the rest of the table.

      FindReplaceEmptyDialog.png

        • 1. Re: Find/Replace produces blank dialog when data loaded from file does not match field requirements
          Markus Schneider

               Just curious: Does it work as expected under 10.8.x? 

          • 2. Re: Find/Replace produces blank dialog when data loaded from file does not match field requirements
            nspies

                 Excellent question: I don't know, but I doubt it. The problem was in my case was that the data file did not, in this one instance, follow the field definition specified. Still, FileMaker 12 Pro Advanced should under no circumstances produce and empty dialog box, particularly a modal dialog.

                 Not having read the documentation that I just was made aware of yesterday I would like to know how FileMaker interprets two or more delimiters (tabs, commas, whatever) in a row. I am too busy to test this easy question at the moment.

                 Based on the knowledge I had when I converted the data files into a tab-delimited form, I made no assumptions as to whether the sequence of delimiters (^ = tab) before an EOL, such as: ^^^¶  would be interpreted as null null null (if FMP 'eats' the first delimiter for each null field), or simply  null null (if FMP 'eats' a _pair_ of delimiters for each null field), or as an import error. I mistrusted how FMP might interpret a series of tabs, forcing me to use a | (pipe, which didn't appear in any of the data) as a stand-in for null, and replacing | with null after the data was in FMP. I chose the first interpretation because this yielded the right number of fields.  This did not take very long using Aquamacs (a Macified Emacs) and some regular expressions. I suppose Perl or some Unix command(s) would have been faster, but I used what I already knew...

                 What is the short answer to the question about how FMP treats a series of delimiters, whether before data or EOL?

            • 3. Re: Find/Replace produces blank dialog when data loaded from file does not match field requirements
              philmodjunk

                   See if you can recreate this with a small, simple test file created brand new for the test.

                   The dialog looks like a validation error message. I don't know if this could be the case here, but I could recreate this result if I specified a custom validation message for a field that is not permitted to be empty and use just a space character for the custom validation message.

                   If it's something like that, you won't see this dialog in the test file.

              • 4. Re: Find/Replace produces blank dialog when data loaded from file does not match field requirements
                nspies

                     I created the small test file and database as suggested and cannot reproduce the error of having a blank dialog as depicted. The data in the database in question was not my own, BTW, and there are no scripts. It just seemed to be a faulty field with a null value. I solved the immediate issue of importing the data by putting a space to satisfy the 'data required' definition.

                     There seems to be no way I can upload the test db...or am I missing something.

                • 5. Re: Find/Replace produces blank dialog when data loaded from file does not match field requirements
                  philmodjunk

                       Validation error messages do not come from scripts. They are set up in Field Options. So you need to Open Manage | Database | Fields and check there.

                       There seems to be no way I can upload the test db...

                       Since the test DB works, I don't see why you would want to upload it, but instead of uploading a file--and only image files of type PNG, GIF and JPG can be uploaded, you can upload the file to a sharing site such as Drop Box and then post the down load link to it here.