9 Replies Latest reply on Oct 1, 2010 9:41 AM by TSGal

    FileMaker reports fields as being used in Privilege when they're not

    nickorr

      Summary

      FileMaker reports fields as being used in Privilege when they're not

      Version

      FMPA 11v3

      Operating system version

      Mac OS 10.6.4

      Description of the issue

      When you have a Privilege Set that uses the "Limited" privilege for a table, and then you change that back to either Yes or No, the fields in the Privilege Set are still referenced and you get warnings when you try to delete fields.

      Steps to reproduce the problem

      Create a new file with a single table and a single field.  Go to the Security settings and add a new privilege set.  Change the Data Access for Records to Custom, and for one of the options, like View, change it to Limited.  Enter a calculation that includes the field from the table.  Ok all of the dialogs and leave Manage Security.

      Go back into Manage Security, and leave the Data Access at Custom but change any of the options to Yes or No instead of limited, so that the calculations are no longer being used.  Leace the Manage security and ok all of the dialogs.

      Go into field definitions and try to delete the field.  It warns you first about deleting the field and then tells you that you can't delete it as it's in use by the Privilege Set you first defined, even though it's no longer in use.

      Expected result

      The delete option shouldn't refer to privilege set calculations that are no longer being used.

      This would be consistent with other places, like a Go To Layout step that has a "By Name" calc and is changed to Original Layout or a Field definition that has an auto enter calc that is turned off.

      In both cases, the step or the field will remember the calculation, but it doesn't refer to it in the process of deleting the fields used, and doesn't give you the warning.

      I would expect it to behave the same way in all situations, so either always show the alert or always not.

      Actual result

      You get the alert for fields that are no longer used in Privileges, but not in steps or field calculations.

      Exact text of any error message(s) that appear

      "FieldName" cannot be deleted because it is used by the privilege "PrivilegeSetName".

      Workaround

      You have to manually find the part of the Privilege set that used to have a calculation, and change it back to limited, then delete the calc, then ok the dialog and change it back again to what it was.

      And you have to repeat this for every place the field was used.

        • 1. Re: FileMaker reports fields as being used in Privilege when they're not
          philmodjunk

          This has quite a few similarities to this bug:   Calculation formula stored even after specifying to not use a calculation

          This is one of many acknowledged bugs that can be found in the Known Bugs List here in the Report an Issue section of the forum.

          It can also be downloaded as a database file from:   http://www.4shared.com/file/8orL8apk/FMP_Bugs.html

          • 2. Re: FileMaker reports fields as being used in Privilege when they're not
            nickorr

            PhilModJunk,

            This is similar to the other issue you referenced, but there are two big difference between the examples.  In the case of the Script Step, the DDR includes the details of the calculation.  With the Privilege Set it doesn't, so you have no way of being able to tell which places within the Priv Set it is used.

            Plus, with the script step, the dialog includes an OK button, so you can override the warning and still delete the field.  When it's in the Privilege Set the dialog is different and has no Ok button, and so you can't override the warning.  This means you have to fix the issue before you can delete the field.

            The problem is that it's inconsistent between the two places.  Either always include the calculations in the DDR or don't, and either always allow the override or don't.

            The other bug report is more that it's retaining the calculation in these places.  In some examples that is useful, so this might not be considered a bug, it's probably considered intentional.  My report is more that the retention of the calculation is inconsistent and causes problems that shouldn't happen.

            Hope this helps.

            Thanks,

            Nick

            • 3. Re: FileMaker reports fields as being used in Privilege when they're not
              Johan Hedman

              If the DDR information isn´t correct how are you then supposed to figure out what´s used in the system or not. Third party programs that uses DDR to get the most information out a solution are very important when working in large solutions and if DDR isn´t correct it´s impossible to be 100% sure if you like to delete a unused field.

              • 4. Re: FileMaker reports fields as being used in Privilege when they're not
                philmodjunk

                Not suggesting the issue is exactly the same, but the similarities are striking and may have the same root cause. In the case of de-selected auto-enterd calculations that refer to the field to be deleted, the behavior is exactly the same when you go to delete the field.

                I made my previous post to help draw attention to the similarities for the Filemaker Inc folks so that they can link the two reports in their system if they think this is a different manifistation of the same bug.

                • 5. Re: FileMaker reports fields as being used in Privilege when they're not
                  TSGal

                  Nicholas Orr:

                  Thank you for your post.

                  Our Development and Software Quality Assurance (Testing) departments are aware of this issue, since it was first reported by you in May, 2005.  There is a lot of discussion on this issue (between Testers and Development).  In essence, the formula is retained in case the user wants to temporarily turn off the feature without losing the formula associated with the privilege set.  I have just attached this entire thread to the original report because it is unedited and it will force the team to revisit this issue again.

                  TSGal
                  FileMaker, Inc.

                  • 6. Re: FileMaker reports fields as being used in Privilege when they're not
                    philmodjunk

                    Seems like retaining the expression isn't the real issue here. The issue is that FileMaker prevents deleting the referenced field instead of just displaying a warning like it does with scripts that reference the field about to be deleted. If it warned us and then let us proceeed with the deletion, we'd be OK with the retained, but disabled expressions.

                    • 7. Re: FileMaker reports fields as being used in Privilege when they're not
                      TSGal

                      PhilModJunk:

                      I understand this is not the "real issue".  I just wanted to provide why the expression is retained.  The reason why I forwarded the entire thread is to give Development and Testing detailed posts from our Customers why this should be changed.

                      TSGal
                      FileMaker, Inc.

                      • 8. Re: FileMaker reports fields as being used in Privilege when they're not
                        nickorr

                        If it helps I'd like to clarify how I see the issues :

                        1 ) First is the question of whether or not this should be retained.  Personally I'd say not between each "Manage" session.  So once you close Define Fields or Manage Security, it should go.  It is useful while modifying things for this to change, but for it to retain a calc that was used three years ago when it was a single table solution doesn't make sense to me.  You will have a different perspective and I don't see this point as the bigger issue.

                        2) Second, I don't think this info should be included in the DDR at all.  Seeing as it's not actually in use it makes the DDR much harder to parse and remove non-used data.  This one is a Feature Request, not a bug, but seeing as I work with the DDR a lot it's one I'd love to see implemented.

                        3) There is what I consider a bug in the code for checking whether or not a field is in use, in that it won't check an "unused" calc in a script step, but will check an "unused" calc in a Privilege Set.  It should behave the same way regardless of where the field was previously used.

                        4) Finally there is a user interface inconsistency between the interface for fields used in Steps vs fields used in Privilege Sets.  When the reference is in a Step I can still override the dialog and delete the field, but for the Privilege Set I cannot.  Again, I think this is a bug and should behave the same way in both places.  This might be a consequence of point 3, or could be unrelated, I'm not sure.

                        Thanks for looking at this, and let me know if you need any other info from me.

                        Cheers,

                        Nick

                        • 9. Re: FileMaker reports fields as being used in Privilege when they're not
                          TSGal

                          Nicholas Orr:

                          Thank you for the additional comments.  I have attached them to the original case.  I will keep you posted with any comments I receive from Development and/or Testing.

                          TSGal
                          FileMaker, Inc.