Google Sheets Nested IF statement

Ralphie8on

New Member
Joined
Jul 2, 2023
Messages
6
Office Version
  1. 365
Platform
  1. Windows
I have a google Sheet with 2 tabs. The second tab is a giant 330 row table of data to be pulled into the first tab. In the first tab I have 30 rows that use the drop down to grab a name from the 2nd tab and fill out the rest of the row. I have attached the link to the doc and you can see what i mean on rows 28 - 57. I am trying to do a nested if statement in cell H20 that reads like this:
Excel Formula:
=If(A28:D57="Mighty 4",G2+4, if(A28:D57="Mighty 3", G2+3, if(A28:D57="Mighty 2", G2+2, if(A28:D57="Mighty 1", G2+1, G2))) )

What i want is that cell to add what is in cell G2 with either 4, 3, 2, or 1 depending on if someone has selected Mighty of that version in the drop down.






https://docs.google.com/spreadsheet...OW-J-a8CDWRWa4zyR_136hxZU/edit?usp=drive_link
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
I keep getting "A matching value can't be found To get the value of the entire range use the ARRAYFORMULA function" Once i add in that function it wants to replace all of the cells in the vicinity. Am I using the right formula or is there a better way to do this or am i just not able to complete this action?
 
Upvote 0
That link isn't public.

What exactly do you mean by this part of the formula:
Excel Formula:
If(A28:D57="Mighty 4"

Are you trying to test if any of those cells contain Mighty 4? Or if all of them do? Or something else? What if one of those cells has Mighty 4 and another has Mighty 3? What should happen?
 
Upvote 0
That link isn't public.

What exactly do you mean by this part of the formula:
Excel Formula:
If(A28:D57="Mighty 4"

Are you trying to test if any of those cells contain Mighty 4? Or if all of them do? Or something else? What if one of those cells has Mighty 4 and another has Mighty 3? What should happen?

I want the highest number to be counted. I thought that if i wrote it with the highest first and down from there that it would stop if it found the correct value.

What I want is for the highest number to be added. Like if Mighty 1 and Mighty 2 were in teh selection I just want the Mighty 2 function to work.
 
Upvote 0
Your formula is testing each cell and returning an array of True/False values. I suspect you want:

Excel Formula:
If(COUNTIF(A28:D57,"Mighty 4")>0
and similar for the other tests.
 
Upvote 0
Solution

Forum statistics

Threads
1,223,950
Messages
6,175,582
Members
452,653
Latest member
craigje92

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top