Filter formula help needed with Spill issues

BrettOlbrys1

Board Regular
Joined
May 1, 2018
Messages
128
Office Version
  1. 365
Platform
  1. Windows
I have the following formula:

=IF($M1="",XLOOKUP($E1,'DATA'!$A:$A,'DATA'!$C:$F),FILTER($M1:$R1,{1,1,0,0,1,1})))

I am applying this formula to cell S1.

If M1 is blank, show data from the DATA sheet cells C:F in cells S1, T1, U1, and V1
If M1 is not blank, filter the data in the current rows data from M1 to R1 and only show cells M1, N1, Q1, and R1 in cells S1, T1, U1, and V1

What I want to add to this formula is another IF statement, such as:


=IF($S1="Unknown",XXX,if($M1="",XLOOKUP($E1,'DATA'!$A:$A,'DATA'!$C:$F),FILTER($M1:$R1,{1,1,0,0,1,1}))))

What I want that XXX to do is fill in cells S1, T1, U1, and V1 with "Unknown" but I don't know how to do that within this rewritten formula?

Any thoughts?

Thanks,

Brett
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
You should never have a formula that looks at it's own cell, as it creates a circular reference.
 
Upvote 0
You should never have a formula that looks at it's own cell, as it creates a circular reference.
Sorry, I mistyped my formula references, here is the correction:

=IF($M1="",XLOOKUP($E1,'DATA'!$A:$A,'DATA'!$C:$F),FILTER($M1:$R1,{1,1,0,0,1,1})))

I am applying this formula to cell T1.

If M1 is blank, show data from the DATA sheet cells C:F in cells T1, U1, V1, and W1
If M1 is not blank, filter the data in the current rows data from M1 to R1 and only show cells M1, N1, Q1, and R1 in cells T1, U1, V1, and W1

What I want to add to this formula is another IF statement, such as:

=IF($S1="Unknown",XXX,if($M1="",XLOOKUP($E1,'DATA'!$A:$A,'DATA'!$C:$F),FILTER($M1:$R1,{1,1,0,0,1,1}))))

What I want that XXX to do is fill in cells T1, U1, V1, and W1 with "Unknown" but I don't know how to do that within this rewritten formula?
 
Upvote 0
Ok, how about
Excel Formula:
=IF($S1="Unknown",{"xxx","xxx","xxx"},IF($M1="",XLOOKUP($E1,Data!$A:$A,Data!$C:$F),FILTER($M1:$R1,{1,1,0,0,1,1})))
 
Upvote 0
Solution
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,653
Messages
6,120,751
Members
448,989
Latest member
mariah3

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