Formula to return a cell value based on criteria

IIII

New Member
Joined
Jan 26, 2021
Messages
18
Office Version
  1. 365
Platform
  1. Windows
  2. Mobile
  3. Web
Hi All,

I have this simple assets tracker attached below. What I'm hoping to do here is to auto-populate the name from Column C (Assigned To), into Column I (Reassigned To) when the same device (by serial # in Column B) has been reassigned to a new user. I've tried using the INDEX w/MATCH function but could only get it to work on the first two rows.

In the example below you can see the same device has been passed around 3 times and is currently assigned to the user 'Steve'.

Fake Business Asset Manager.xlsx
ABCDEFGHIJK
1Asset_TypeSerial_Device_#Assigned_ToDepartmentAssigned_LocationAssigned_DateUnassigned_DateReassignedReassigned ToNotesBarcode
2PC2734807049John DoeFinanceOffice01/01/202301/05/2023YesDave
3PC2734807049DaveCustomer ServiceOffice01/05/202323/05/2023YesSteve
4PC2734807049SteveHelpdeskHome23/05/2023
Sheet1


Thanks for any help with this and appreciate your time.

Cheers.
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN
How about
Fluff.xlsm
ABCDEFGHIJK
1Asset_TypeSerial_Device_#Assigned_ToDepartmentAssigned_LocationAssigned_DateUnassigned_DateReassignedReassigned ToNotesBarcode
2PC2734807049John DoeFinanceOffice4492745047YesDave
3PC2734807049DaveCustomer ServiceOffice4504745069YesSteve
4PC2734807049SteveHelpdeskHome45069Steve
Main
Cell Formulas
RangeFormula
I2:I4I2=FILTER($C$2:$C$4,($B$2:$B$4=B2)*($F$2:$F$4=G2),C2)
 
Upvote 0
Two different ways.
MrExcelPlayground17.xlsx
ABCDEFGHIJK
1Asset_TypeSerial_Device_#Assigned_ToDepartmentAssigned_LocationAssigned_DateUnassigned_DateReassignedReassigned ToNotesBarcode
2PC2734807049John DoeFinanceOffice1/1/20235/1/2023YesDave
3PC2734807049DaveCustomer ServiceOffice5/1/20235/23/2023YesSteve
4PC2734807049SteveHelpdeskHome5/23/2023YesHarry
5PC123456FredHelpdeskOffice5/24/2023YesJamie
6PC2734807049HarryHelpdeskHome5/25/2023YesSally
7PC123456JamieHelpdeskOffice5/26/2023No 
8PC2734807049SallyHelpdeskOffice5/27/2023YesMary
9PC2734807049MaryHelpdeskHome5/28/2023 
10
11
12
13Asset_TypeSerial_Device_#Assigned_ToDepartmentAssigned_LocationAssigned_DateUnassigned_DateReassignedReassigned ToNotesBarcode
14PC2734807049John DoeFinanceOffice1/1/20235/1/2023YesDave
15PC2734807049DaveCustomer ServiceOffice5/1/20235/23/2023YesSteve
16PC2734807049SteveHelpdeskHome5/23/20235/23/2023YesSteve
17PC123456FredHelpdeskOffice5/24/20235/24/2023YesFred
18PC2734807049HarryHelpdeskHome5/25/20235/26/2023YesSally
19PC123456JamieHelpdeskOffice5/26/2023 
20PC2734807049SallyHelpdeskOffice5/27/20235/28/2023YesMary
21PC2734807049MaryHelpdeskHome5/28/2023 
Sheet17
Cell Formulas
RangeFormula
F5:F9,F17:F21F5=F4+1
I2:I8I2=IF(H2="Yes",XLOOKUP(B2,B3:B$9,C3:C$9,"",0),"")
I9I9=IF(H9="Yes",XLOOKUP(B9,B$9:B10,C$9:C10,"",0),"")
I14:I21I14=IF([@Reassigned]="Yes",INDEX(SORT(FILTER(Table6[[Assigned_To]:[Assigned_Date]],([Assigned_Date]>=[@[Unassigned_Date]])*([Serial_Device_'#]=[@[Serial_Device_'#]])),4),1,1),"")
 
Upvote 0
Solution
Thanks @Fluff and @JamesCanale for taking the time to respond.

@JamesCanale - your 2nd solution (Index/Sort etc.) hit the nail on the head! Thanks mate.

Appreciate the help everyone.

Cheers.
 
Upvote 0

Forum statistics

Threads
1,223,164
Messages
6,170,444
Members
452,326
Latest member
johnshaji

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