Filter report where Current User <> Me

  • 2
  • 1
  • Question
  • Updated 9 months ago
  • Answered
Filter report [Assigned to] <> Current User
Photo of David Knight

David Knight

  • 154 Points 100 badge 2x thumb

Posted 1 year ago

  • 2
  • 1
Photo of Matthew Neil

Matthew Neil

  • 31,478 Points 20k badge 2x thumb
I don't think that is an option, but you could make a formula checkbox with the same logic, and then use that as a filter (or even a dynamic filter).
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 52,786 Points 50k badge 2x thumb
Or make a formula user field called Current User with a formula of

User()

and filter against that field
Photo of David Knight

David Knight

  • 154 Points 100 badge 2x thumb
Thank you both. The Current User with formula did the trick.
Photo of Johnny QuickBase

Johnny QuickBase

  • 300 Points 250 badge 2x thumb
I"m not sure how that the current user formula field is supposed to filter a report.  How do you filter based on current user with nothing but a formula field that gives you the current user?
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 52,786 Points 50k badge 2x thumb
You compare current user to another field in your table.

For example where [record owner] equals current user.

That would be a report of records that I created.
Photo of Johnny QuickBase

Johnny QuickBase

  • 300 Points 250 badge 2x thumb
I have reports where when some user field equals current user to create reports.  What I am trying to do is create a filter on a report for current user.  So that a user could go to say a table homepage report, use the current user filter and they would see their items.
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 52,786 Points 50k badge 2x thumb
If you want to have a Dynamic Filter for where a User field on records is equal to the Current User, just make a formula checkbox field

[My User field] = User()

Then use that as a Dynamic Filter.
Photo of Johnny QuickBase

Johnny QuickBase

  • 300 Points 250 badge 2x thumb
Thanks.  Can a formula checkbox field have an IF formula?   Say if I have more than 1 field that I want to check is the current user?   In my scenario I have 2 user list fields, assigned to, and reported by.  I want to check if either field is the current user. 

I'm trying to make it easier for people to find their items without having to go to a specific "my items" report. 
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 52,786 Points 50k badge 2x thumb
An IF statement can be as simple or as complex as  you like. If you are able to express what you want in plain words, then there is always a way to get to the syntax for the formula.


for example

IF(
[assigned to]  = User(), true,
[reported by]  = User(), true)

That will be true of either of the above are true.

Mark
Photo of Johnny QuickBase

Johnny QuickBase

  • 300 Points 250 badge 2x thumb
Thanks Mark,

I thought maybe I had missed something because I tried this, and was getting errors.
Mine are userlist fields and says cannot be used with User()

"The expression [Assigned To] on the left hand side of the operator "=" is of type userlist while the expression User() on the right hand side is of type user. The operator "=" cannot be used with these types of expressions."
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 52,786 Points 50k badge 2x thumb
OK, I did not know they were userlist field types.

Try this

IF(
Includes([assigned to], ToUserlist(User())), true,
Includes([reported by], ToUserlist(User())))
Photo of Johnny QuickBase

Johnny QuickBase

  • 300 Points 250 badge 2x thumb
Awesome! Thanks Mark.  I always forget the ToUserlist...  Remembering formulas is not my strong suite.   That worked.  Thank you.