3 Replies Latest reply on Feb 8, 2012 3:23 PM by philmodjunk

    Filtering results in a table by the current user



      Filtering results in a table by the current user



      Trying to get my head around User Accounts in filemaker. 2 questions:

      1. I have a table with some records in a table with a column that has values that are named to various users in the permissions list. How do I go about filtering those values based on the user that logs in?

      2. Taking it one step further, what would be the best way to manage user accounts? If I have an employee table, do I have to manually keep track of the Employees username in the employee table? Or is there a better way of doing this?



        • 1. Re: Filtering results in a table by the current user

          1. This sounds like something you can set up with a conditional value list. Putting the user's account name in a field linked to a table where you have one record for each value in the value list would make this possible. Do you know how to do this? If not, see these links first:

          Forum Tutorial: Custom Value List?

          Knowledgebase article: http://help.filemaker.com/app/answers/detail/a_id/5833/kw/conditional%20value%20list

          Demo File: http://www.4shared.com/file/f8NsU2DJ/ConditionalValueListDemo.html

          2. that's a hard one to answer. Basic security needs can be managed directly from Manage | Security where you can add and change accounts as needed. If you need such things as record level access control, have a database consisting of multiple password protected files, want to enable a user that does not have full access to manage accounts or other more complex scenarios, then a table of account names and specfied privilege sets may be very useful--along with scripts and global fields for automating the process of editing account settings. (To enable a less then full access user to change account settings, use the "run with full access permissions" setting on scripts created to make the account changes.)

          • 2. Re: Filtering results in a table by the current user

            Thanks for the reply.

            Trying to apply the tutorials to my database.

            An odd error though, do value lists have trouble displaying data from fields that are based on a calculation? In my employee table, I have a "Full Name" field that is calculated by adding First Name and Last Name together (I used [First Name & " " & Last Name] as the calculation).

            FM displays 3 entries for every field other than the "Full Name" field.


            • 3. Re: Filtering results in a table by the current user

              You should be able to use calculation fields as a source of values. As long as they aren't unstored calculations. Check to make sure that the return type specified in the calculation is text and not number.