Addning one more condition to Formula

Edwardryez

New Member
Joined
Apr 28, 2014
Messages
48
I compare and update Columns in a table based in this formula:
=IF(AND(I2<>"",J2<>""),IF(J2-I2<>0,J2-I2,"Same"),IF(J2<>"","New",IF(AND(I2="",J2=""),"None","Removed")))
How can i modify that if = Removed then all the Row Cells After instead of =None, =Removed?
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.

gaz_chops

Well-known Member
Joined
Apr 29, 2003
Messages
6,485
Platform
  1. MacOS
Not sure about the different elements of your formula? Break it down, what do you want returned for each IF statement?

IF(AND(I2<>"",J2<>"")
IF(J2-I2<>0,J2-I2
IF(J2<>""
IF(AND(I2="",J2=""

 
Upvote 0

Edwardryez

New Member
Joined
Apr 28, 2014
Messages
48
Not sure about the different elements of your formula? Break it down, what do you want returned for each IF statement?

IF(AND(I2<>"",J2<>"")
IF(J2-I2<>0,J2-I2
IF(J2<>""
IF(AND(I2="",J2=""

Let say i have the results in V
I compare Column Values I,J and if they are =, V="Same", if I="" and J<>"", V="New", If I<>"" and J="", V="Removed", If I="" and J="", V="None""

Next Column W get the Result from Comparing J and K, after Value Removed on V, W becomes "None" since J="" and K"", how can i keep it "Removed"?
 
Upvote 0

gaz_chops

Well-known Member
Joined
Apr 29, 2003
Messages
6,485
Platform
  1. MacOS
Let say i have the results in V
I compare Column Values I,J and if they are =, V="Same", if I="" and J<>"", V="New", If I<>"" and J="", V="Removed", If I="" and J="", V="None""

Next Column W get the Result from Comparing J and K, after Value Removed on V, W becomes "None" since J="" and K"", how can i keep it "Removed"?

Tell me for each If what result you expect, copy and paste this and add to the end what you expect.

IF(AND(I2<>"",J2<>"")
IF(J2-I2<>0,J2-I2
IF(J2<>""
IF(AND(I2="",J2=""
 
Upvote 0

Edwardryez

New Member
Joined
Apr 28, 2014
Messages
48
ADVERTISEMENT
IF(J2-I2<>0,J2-I2,"Same"),IF(J2<>"","New",IF(AND(I2="",J2=""),"None","Removed"
 
Upvote 0

gaz_chops

Well-known Member
Joined
Apr 29, 2003
Messages
6,485
Platform
  1. MacOS
Now you have gone from 4 IFs to 3?

=IF(and(J2-I2<>0,J2-I2),"Same",IF(J2<>"","New",IF(AND(I2="",J2=""),"None","Removed"
 
Upvote 0

Edwardryez

New Member
Joined
Apr 28, 2014
Messages
48
ADVERTISEMENT
thats what i need the 4th.
Lets say if I2="Removed" J2="Removed"
 
Upvote 0

gaz_chops

Well-known Member
Joined
Apr 29, 2003
Messages
6,485
Platform
  1. MacOS
Not sure but try

=IF(AND(I2="",J2="",COUNTA($I2:I2)=0),"None",IF(OR(J2>I2,AND(I2="",J2<>"")),"New",IF(AND(COUNTA(I2:J2)<>0,I2=J2),"Same","Removed")))
 
Upvote 0

Forum statistics

Threads
1,195,644
Messages
6,010,893
Members
441,571
Latest member
stolenweasel

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
Top