Getting User Role

  • 0
  • 1
  • Question
  • Updated 4 months ago
  • Answered
I have 4 user fields in my application.  I retrieve the user name by using UserToName in a formula text field.  I have a user table that has the user id, name, email address and role.  I need to be able to pull the role of the user from the user table but not sure how to do this since I have 4 user fields and I will need the role for the user in each field.

I don't know API, so I don't think that is an option for me at time.

Thanks,
Photo of cowannbell

cowannbell

  • 1,350 Points 1k badge 2x thumb

Posted 4 months ago

  • 0
  • 1
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 69,592 Points 50k badge 2x thumb
Assuming that the Key field of the User table is set to say the Userid, you will need to set up 4 relationships to get the 4 respective Roles.
Photo of cowannbell

cowannbell

  • 1,350 Points 1k badge 2x thumb
Right now the record ID is the key field.  Should I change that to the email?
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 69,592 Points 50k badge 2x thumb
Yes, if you choose to change it to the email field then you can make a field on the child side like

UserToEmail([my user field 3])

 and use that in the relationship.
Photo of cowannbell

cowannbell

  • 1,350 Points 1k badge 2x thumb
Thanks, that works great.