Compare users in fields

  • 0
  • 1
  • Question
  • Updated 9 months ago
  • Answered
I need to compare Field A and Field B below.  Field A is a multiple user select and B is a multiple choice.  The users in Field A have been selected to approve a document.  They must all complete before the approval is complete.  I have created a checkbox to do this.
Contains([Quality Approval],(Part(UserListToNames([Quality Team]),1,";"))&"] Approved") and
Contains([Quality Approval],(Part(UserListToNames([Quality Team]),2,";"))&"] Approved") and etc.

My issue is I want to know which user the approval is waiting on.  So if a 10 users in Field A are required and only 9 have approved- which user am I waiting on.  I am putting a lot of documents through our system and would like a way to see this quickly.

 
Photo of Sarah Bunten

Sarah Bunten

  • 664 Points 500 badge 2x thumb

Posted 9 months ago

  • 0
  • 1
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 26,522 Points 20k badge 2x thumb
Assuming your draft formula is correct the following might work:
var Text QTA = Part(UserListToNames([Quality Team]), 1, ";");
var Text QTB = Part(UserListToNames([Quality Team]), 2, ";");
var Text QTC = Part(UserListToNames([Quality Team]), 3, ";");
var Text QTD = Part(UserListToNames([Quality Team]), 4, ";");
If (not Contains([Quality Approval], $QTA & "] Approved"), $QTA) & 
If (not Contains([Quality Approval], $QTB & "] Approved"), $QTB) &
If (not Contains([Quality Approval], $QTC & "] Approved"), $QTC) &
If (not Contains([Quality Approval], $QTD & "] Approved"), $QTD
The formula basically concatenates together those users in the Quality Team that don't appear in the Quality Approval log.

But if there is a possibility that in the Quality tame may initially approve the request but later withdraw their approval the above formula would incorrectly classify their actions a approved.

Script would provide a solution that covers all cases.

Another approach would be to create a child table and the appropriate summary fields and reports. But I assume you like the compact display of the user list and logging field. I would like to hear Mark's input on using the child table.
(Edited)
Photo of Sarah Bunten

Sarah Bunten

  • 664 Points 500 badge 2x thumb
Works Great!  Thanks
Photo of Sarah Bunten

Sarah Bunten

  • 664 Points 500 badge 2x thumb
One issue:  If they state rejected then their name should not show up.  So in other words, they just need to respond: Approve or reject.  How do I add that in there?
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 51,436 Points 50k badge 2x thumb
I would go with Dan's solution and work though any small syntax problems which arise if there are any.

Let us know how it goes.
Photo of Sarah Bunten

Sarah Bunten

  • 664 Points 500 badge 2x thumb
One issue:  If they state rejected then their name should not show up.  So in other words, they just need to respond: Approve or reject.  How do I add that in there?