+ Reply to Thread
Results 1 to 4 of 4

Problems adding a "refer to text in cell" query to a working nested if-and formula

  1. #1
    Registered User
    Join Date
    03-25-2014
    Location
    Notingham, England
    MS-Off Ver
    Excel 2007
    Posts
    6

    Problems adding a "refer to text in cell" query to a working nested if-and formula

    Good morning

    As my garbled title suggests, I am having some trouble with a nested IF formula.

    I have created a spreadsheet sheet to assess pension scheme members individual data and categorise accordingly. The IF formula references the individual's date of birth and annual earnings to provides the result as the category of member, as below.

    =CONCATENATE(IF(AND(F37>9999,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER - Aged 22-65 with qualifying earnings over £9999",""),
    IF(AND(F37<5772,E37>$F$10,E37<$F$9),"ENTITLED WORKER - Aged 16-74 with qualifying earnings below £5772",""),
    IF(AND(F37>9999,E37<$F$9,E37>$F$8),"NON ELIGIBLE JOBHOLDER - Aged 16-21 with qualifying earnings above £9999",""),
    IF(AND(F37>9999,E37<$F$7,E37>$F$10),"NON ELIGIBLE JOBHOLDER - Aged 65-74 with qualifying earnings above £9999",""),
    IF(AND(F37<10000,F37>5771,E37<$F$9,E37>$F$10),"NON ELIGIBLE JOBHOLDER - Aged 16-74 with qualifying earnings £5772-£9999",""))

    I now want to expand this formula to refer to whether the individual is weekly, monthly, quarterly paid. I have created a drop down box in another cell to allow the user to select the pay frequency and wanted to add another query to the formula to refer to the text in the pay frequency cell.

    I tried to create additional queries for each of the 5 above, changing the earnings figure to account for the fact that the member is weekly,monthly,quarterly...paid. An example of my attempted formula for the first of the above queries is shown below (cell D5 being the selected payment frequency):

    =CONCATENATE(IF(AND(D5=”Annually”,F37>=$G$33,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER - Aged 22-65 with qualifying earnings over £9999",""),
    IF(AND(D5=”Bi-annually”,F37>=$G$32,E37>$F$7,E37<$F$8,"ELIGIBLE JOBHOLDER - Aged 22-65 with Qualifying Earnings Over £4,999",""),
    IF(AND(D5="Quarterly",F37>=$g$31,E37>$F$7,E37<$F$8,”ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £2499”,””),
    IF(AND(D5="Monthly”,F37>=$g$30,E37>$F$7,E37<$F$8,”ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £832”,””),
    IF(AND(D5="4 weekly",F37>=$g$29,E37>$F$7,E37<$F$8,”ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £768”,””),
    IF(AND(D5="Fortnightly”,F37>=$g$28,E37>$F$7,E37<$F$8,”ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £384”,””),
    IF(AND(D5="Weekly*,F37>=$g$27,E37>$F$7,E37<$F$8,”ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £191”,””),

    I am not able to get this to work, or savy enough to identify my shortfalls on this issue.

    Any assistance would be greatly appreciated.

    Thanks,

    Stewart

  2. #2
    Forum Contributor
    Join Date
    03-17-2005
    Location
    Canterbury, Kent
    MS-Off Ver
    2003, 2010
    Posts
    285

    Re: Problems adding a "refer to text in cell" query to a working nested if-and formula

    Hi Stewart

    You are missing the closing parentheses on your and functions

    Try:
    =CONCATENATE(IF(AND(D5="Annually",F37>=$G$33,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER - Aged 22-65 with qualifying earnings over £9999",""),
    IF(AND(D5="Bi-annually",F37>=$G$32,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER - Aged 22-65 with Qualifying Earnings Over £4,999",""),
    IF(AND(D5="Quarterly",F37>=$G$31,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £2499",""),
    IF(AND(D5="Monthly",F37>=$G$30,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £832",""),
    IF(AND(D5="4 weekly",F37>=$G$29,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £768",""),
    IF(AND(D5="Fortnightly",F37>=$G$28,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £384",""),
    IF(AND(D5="Weekly",F37>=$G$27,E37>$F$7,E37<$F$8),"ELIGIBLE JOBHOLDER – Aged 22-65 with Qualifying Earnings Over £191",""))

    Windy

  3. #3
    Registered User
    Join Date
    03-25-2014
    Location
    Notingham, England
    MS-Off Ver
    Excel 2007
    Posts
    6

    Re: Problems adding a "refer to text in cell" query to a working nested if-and formula

    Thank you so much, spreadsheet now functional. Apologies if this was a daft question.

    Stewart

  4. #4
    Forum Contributor
    Join Date
    03-17-2005
    Location
    Canterbury, Kent
    MS-Off Ver
    2003, 2010
    Posts
    285

    Re: Problems adding a "refer to text in cell" query to a working nested if-and formula

    No problem, sometimes you cannot see the wood for the trees.

    You also had a * instead of "".
    And some of your double quotes look different weather this made a difference I don't know

    Windy

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] IF Formula not working - need to return "NO" if cell is 1% greater or "YES" if less 1%
    By maryren in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-26-2013, 11:34 AM
  2. solution for the blank cell using the IF function
    By ragnaedge in forum Excel General
    Replies: 4
    Last Post: 08-23-2013, 11:03 AM
  3. Update Query Not Working. "Operation must use an updateable query"
    By jdgwebdev in forum Access Tables & Databases
    Replies: 0
    Last Post: 03-19-2013, 01:19 PM
  4. Replies: 5
    Last Post: 08-08-2012, 04:08 PM
  5. Replies: 5
    Last Post: 01-10-2012, 11:20 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1