I have a text field (Recruiters_working_on__c) on the object ts2__Job__c that contains the names of multiple users in String form. I want to return a list of Users if the Recruiters_working_on__c field contains the name of a User. This is what I have but it's returning no results -

public with sharing class getOpenRecuiters {
public static List<User> getOpenRecuiters() {
   List<ts2__Job__c> reqs = new List<ts2__Job__c>();
   List<String> users = new List<String>();
   reqs = [SELECT Recrutiers_Working_On__c FROM ts2__Job__c WHERE Division__c = 'MS' AND ts2__Status__c = 'Open'];
   for (ts2__Job__c user : reqs) {
   return [SELECT Name FROM User WHERE Name IN :users];    


1 Answer 1


change users.add(string.valueOf(user)); to


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .