Forum Discussion

WendyShoef's avatar
WendyShoef
Qrew Cadet
7 years ago

Look up record in table associated to current user

Overview: User clicks on formula url button that updates 5 fields in the record (to trigger certain automations or actions)

One of the fields needs to be updated with the value from a numeric field from the corresponding user's employee record so that the value can be used in an automation. 

I've figured out how to save the current user in the update, but I can't figure out how to look up a value in a table that's related to the current user, not the current record/table. 

I've thought of a few options, but I'm stuck on how to implement them so I'm hoping someone can help me out with a solution.

  • No problem

    If the employee are all users, you can set the Key field of the EE table to be the userid and then make a relationship to the details table using a reference field on the right side of the relationship of the field I like to call [Current User] with a formula user formula of

    User()

    If not all employee have userid�s or for other reason you are unwilling to change the key field, then you can make a Sync table of selected fields from the EE table and set the Userid in text format ( it will sync across as text) to be the key field. Only bring across EEs with a userid.

    Then make a reference field with theformula

    ToText(User())

    To make the relationship.
    • WendyShoef's avatar
      WendyShoef
      Qrew Cadet
      When I try to connect the table, it only gives me options for tables in the first app that was created, not the app that I'm using. 
    • WendyShoef's avatar
      WendyShoef
      Qrew Cadet
      FYI, it's not that we are unwilling to change the key field, it's just that there are employees that are not users of QuickBase.  And also, we need to be able to see the information of employees that are no longer with the company in our reporting. 
    • QuickBaseCoachD's avatar
      QuickBaseCoachD
      Qrew Captain
      Right, hence the suggestion to only Sync across EEs who did have a userid.  There is a filter when you build the Sync Connected table.

      As for building the Connection, if the employee data is in a different app, you will need to make a new Quick Base Connection to get at that other App.  Note that these Connections are owned by a user, so its best practice to have them owned by a userid which is like an Admin userid that is not actually a person, but rather a userid owned by the IT department.