Sumproduct to grab only second value in set

briankb64

New Member
Joined
Mar 9, 2020
Messages
3
Office Version
  1. 365
Platform
  1. Windows
Hi All -

I have a table set up that is similar to below (though it expands for multiple years and has many other names on it). My goal is to set up a function that will only grab the second non-blank value for Brian.

As of now I have arrays set up for Date (Dates2), Time (Times), The actual data set C2:C4 in this instance (Array1), and the names from C1:Z1 (Names).

The formula I am plugging in consistently returns 0 =SUMPRODUCT((Rads=C$1)*(Dates2=$A2)*(Array1<>"")*(SMALL(TIMES,2)),Array1)

If I drop out the Small part =SUMPRODUCT((Rads=C$1)*(Dates2=$A2)*(Array1<>""),Array1) the formula works and returns 65. The goal is to only return 50. Can anyone help point me in the correct direction?

DateTimeBrian
1/1/201912:00:00 AM
1/1/20191:00:00 AM15
1/1/20192:00:00 AM50
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
Welcome to the Forum!

Perhaps something like this:

Test.xlsx
ABCDE
1DateTimeBrianSueMary
21/01/20197
31/01/201915218
42/01/2019336
51/01/2019444
61/01/2019502
7
8
9
10MaryBrianSue
11Date1/01/20191/01/20191/01/2019
12Position323
13Result25044
Sheet1
Cell Formulas
RangeFormula
C13:E13C13=INDEX(XLOOKUP(C10,RADS,Array1),SMALL(IF(XLOOKUP(C10,RADS,Array1)*(Dates2=C11),SEQUENCE(ROWS(Array1))),C12))
Named Ranges
NameRefers ToCells
Array1=Sheet1!$C$2:$E$6C13:E13
Dates2=Sheet1!$A$2:$A$6C13:E13
RADS=Sheet1!$C$1:$E$1C13:E13
 
Upvote 0
Hi Stephen! Thank you for your reply but unfortunately I do not have the monthly version of Office 365 and the xlookup/sequence formulas will not be available to me until July.
 
Upvote 0
I do not have the monthly version of Office 365 and the xlookup/sequence formulas will not be available to me until July.

Ah! My mistake - wishful thinking.

Try C13: =INDEX(Array1,SMALL(IF(INDEX(Array1,,MATCH(C10,RADS,))*(Dates2=C11),ROW(Array1)-MIN(ROW(Array1))+1),C12),MATCH(C10,RADS,)) array-entered
 
Upvote 0

Forum statistics

Threads
1,214,907
Messages
6,122,183
Members
449,071
Latest member
cdnMech

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