How can I get my formula to return a phrase instead of #INVALID VALUE

I have a sheet that lists job openings. There is a column formula that assigns a "status" for each job by searching another sheet of applications. For example, if a job has 3 associates applications, and their statuses are "New" "Interviewing" and "Offer" it assigns that job a status of 'offer" because that is the furthest application. I use the formula below, and it works really well, except in cases where the requisition has not applications. It returns "#INVALID VALUE".

Is there a way to edit this formula so that if it finds no applications associated with the req# at the row, it will return the value "no applications"


=

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="BG - Applicant Pool"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="BG - Form Completed"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="BG - Started"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="BG - Under Review"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="BG - In Process"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="OF - Accepted"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="OF - Extended"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="OF - Applicant Pool"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="OF - Extended"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="OF - Ready to Extend"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="OF - Pending"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="OF - Pending Approval"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="OF - Ready to Extend"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="HM - Interview Scheduled"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="HM - Eligible to Schedule"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="HM - Review"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="PS - Scheduled"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="PS - Eligible to Schedule"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="RS - Applicant Pool"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="AB - Incomplete"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="RM - Talent Community"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="RM - TalentPool"), 1), 

IFERROR(INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="AP - Incomplete"), 1), 

INDEX(COLLECT({Status}, {Req Number}, =[Req Number]@row, {Status}, ="AP - Applicant Pool"), 1))))))))))))))))))))))))

Tags:

Best Answer

Answers

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!