Forum Discussion

ChristineWhite's avatar
ChristineWhite
Qrew Assistant Captain
5 years ago

Is Current User Filter with User-List field?

Is it possible to create "Is Current User" report filter using a user-List field?

------------------------------
Christine White
------------------------------
  • The easiest way is to create a formula list user field 

    ToUserList(User())

    and use that in the filter

    ------------------------------
    Mark Shnier (YQC)
    Quick Base Solution Provider
    Your Quick Base Coach
    http://QuickBaseCoach.com
    mark.shnier@gmail.com
    ------------------------------
    • ChristineWhite's avatar
      ChristineWhite
      Qrew Assistant Captain
      Thank you, I am not familar with this formula.  Can you show me the format?   [Report(s) To]  (this is a user list field


      ------------------------------
      Christine White
      ------------------------------
      • MarkShnier__You's avatar
        MarkShnier__You
        Icon for Qrew Legend rankQrew Legend
        You would make a formula called [Current User in List user format] with the formula I provided.

        then filter your report where

        [Report(s) To]  Includes the User in the field [Current User in List user format]



        ------------------------------
        Mark Shnier (YQC)
        Quick Base Solution Provider
        Your Quick Base Coach
        http://QuickBaseCoach.com
        mark.shnier@gmail.com
        ------------------------------
    • MICHAELSARGENT's avatar
      MICHAELSARGENT
      Qrew Cadet
      Mark, that doesn't seem work.  I have an existing List-User field with a list of project managers to whom an individual record may be assigned.  I want to do the same thing as the other person, whereby I'm trying to have the report show a chart for only those projects assigned to the current user (current user = user selected in List-User field).  The formula ToUserList(User([existing list-user field])) throws an error 'the field is not compatible with the parameter field type'.  The report seemed to suggest i was able to display results for the current user in that field, but no results came back even though other conditions were met.  Thoughts?

      ------------------------------
      Michael Sargent
      ------------------------------
      • MarkShnier__You's avatar
        MarkShnier__You
        Icon for Qrew Legend rankQrew Legend
        Hi Michael,

        The function User() returns the current user.

        But Quick Base does not like comparing apples to oranges in a report filter and to Quick Base, a field of type List User cannot be compared with a field of type User in a report filter.  So if the report does not natively offer up to company to "the current user", then a work around is to create a List User formula field which just has the current user in it, ie just 1 user ecven though it is a List User field type.

        So to make that field we use

        ToUserlist (User())

        and call it like [Current User in List User format]

        Then the report will be filtered where

        [Project Managers] include the value in the field [Current User in List User format]




        ------------------------------
        Mark Shnier (YQC)
        Quick Base Solution Provider
        Your Quick Base Coach
        http://QuickBaseCoach.com
        mark.shnier@gmail.com
        ------------------------------
  • Another way I've found is to use the _curuser_ field reference.

    An example would be to have a list of users, and in the filter section of the report do

      includes the user(s) _curuser_ 

    You can get a bunch of these field references from here (I think you would just use underscores in reports though: Markers, User Tokens, and Field References – Quickbase Help



    ------------------------------
    Nolan Pilozo
    ------------------------------
    • JannieCoetzee's avatar
      JannieCoetzee
      Qrew Member

      Thank you guys, I will go and give this a go. Thanks for the info.



      ------------------------------
      Jannie Coetzee
      ------------------------------