Pulling loan # for specific employees into a different sheet.

Cyndi2210

New Member
Joined
Jul 12, 2018
Messages
17
Office Version
  1. 2016
Platform
  1. Windows
Hi,

I am trying to show the value from the "Description" column from the "Loans" sheet into the "Data" sheet for the specific employee. Type 401L should populate Loan ID 1 and 401L2 should populate Loan ID 2. Any person without a loan should display as blank.

Thanks in advance for your help.
 

Attachments

  • Example.jpg
    Example.jpg
    135.5 KB · Views: 5

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
You're example does not have any related Employee ID's in the two tables.
Assuming that eventually you'll have an EmployeeID match.

Please update your profile and advise which version of excel you use. Also, the xl2bb add in (link below) is the best way to share your questions/data and best help the forum help you.

Book1
ABCDE
1Data
2Emp#Loan ID1Loa ID2
360
465
56680462
67280463
7
8LoansTypeDESCR
9102401L 
101409401L 
1166401L80462
1272401L280463
13
Sheet1
Cell Formulas
RangeFormula
D9:D12D9=IFERROR(INDEX(INDEX($B$3:$C$6,MATCH(A9,$A$3:$A$6,0),0),MATCH(B9,{"401L","401L2",0})),"")
 
Upvote 0
I am missing something because it didn't work. They are in separate sheets within the workbook. I've inserted all the people with loans and a few without loans. I am using Microsoft® Excel® 2016 MSO (Version 2401 Build 16.0.17231.20194) 64-bit

DataLoans
ABCDEFABCD
Employee #Loan ID 1Loan Payment 1Loan ID 2Loan Payment 2Rothemployee_idTypeLoan AmountLoan #
102
21.34​
102401L
21.34​
80478
198202401L
32.45​
80479
202
5.75​
220401L
5.75​
80484
216287401L
21.07​
80488
220609401L
26.7​
80472
287
21.07​
609401L2
31.15​
80473
609
26.70​
705401L
103.1​
80465
665705401L2
63.51​
80464
705
103.10​
1409401L
26.22​
80486
1409
26.22​
1586401L
70.03​
80462
1586
70.03​
23.36​
1586401L2
23.36​
80463
2709
38.81​
35.18​
2709401L
38.81​
80477
3889
40.51​
147.49​
2709401L2
35.18​
80476
4676
15.48​
34.96​
3889401L
40.51​
80466
51123889401L2
147.49​
80467
5239
111.59​
4676401L
15.48​
80482
7741
156.14​
166.21​
4676401L2
34.96​
80483
80185239401L
111.59​
80485
8146
32.45​
7741401L
156.14​
80480
8418
37.83​
77.00​
7741401L2
166.21​
80481
8869
26.62​
8146401L
32.45​
80470
88838418401L
37.83​
80468
9045
42.69​
8418401L2
77​
80469
9358
74.82​
8869401L
26.62​
80474
9045401L
42.69​
80471
9358401L
74.82​
80475
 
Upvote 0
Ok, I did it backwards.

Book1
ABCDEFGHIJKL
1DataLoans
2ABCDEFABCD
3Employee #Loan ID 1Loan Payment 1Loan ID 2Loan Payment 2Rothemployee_idTypeLoan AmountLoan #
41028047821.34 102401L21.3480478
5198  202401L32.4580479
6202804795.75 220401L5.7580484
7216  287401L21.0780488
822080484 609401L26.780472
92878048821.07 609401L231.1580473
106098047226.7080473705401L103.180465
11665  705401L263.5180464
1270580465103.10804641409401L26.2280486
1314098048626.22 1586401L70.0380462
1415868046270.038046323.361586401L223.3680463
1527098047738.818047635.182709401L38.8180477
1638898046640.5180467147.492709401L235.1880476
1746768048215.488048334.963889401L40.5180466
185112  3889401L2147.4980467
19523980485111.59 4676401L15.4880482
20774180480156.1480481166.214676401L234.9680483
218018  5239401L111.5980485
2281468047032.45 7741401L156.1480480
2384188046837.838046977.007741401L2166.2180481
2488698047426.62 8146401L32.4580470
258883  8418401L37.8380468
2690458047142.69 8418401L27780469
2793588047574.82 8869401L26.6280474
289045401L42.6980471
299358401L74.8280475
Sheet1
Cell Formulas
RangeFormula
B4:B27,D4:D27B4=IFERROR(INDEX($K$4:$K$29,MATCH($A4&IF(B$3="Loan ID 1","401L","401L2"),$H$4:$H$29&$I$4:$I$29,0)),"")
 
Last edited:
Upvote 0
I still can't get it to work. Here is the formula converted to my actual spreadsheet.
=ERROR(INDEX(Loans!$D$2:$D$27,MATCH($A2&IF(P$1="Loan ID 1","401L","401L2"),Loans!$A$2:$A$27&Loans!$B$2:$B$27,0)),"")

For Reference (Data) P=Loan ID 1 & R=Loan ID 2, but the column names in Loans are correct.

It is a very complicated spreadsheet from a query & this is the last formula.

I'm really sorry to be so obtuse.
 
Upvote 0
you are not being obtuse. But, I think you missed the "IF" in IFERROR.
 
Upvote 0
Hmm. Well, it worked when I copied my mini worksheet above into a new workbook and two worksheets.
Have you tried that? Just to get it working on your end? (Name the initial worksheet Data, create a 2nd sheet name it Loans, then CUT and past Loans into the new Loans Worksheet). From there you should be able to work out any issues, I think.

This is the Data tab:
Book1
ABPRST
1Employee #Loan ID 1Loan Payment 1Loan ID 2Loan Payment 2Roth
21028047821.34 
3198  
4202804795.75 
5216  
622080484 
72878048821.07 
86098047226.780473
9665  
1070580465103.180464
1114098048626.22 
1215868046270.038046323.36
1327098047738.818047635.18
1438898046640.5180467147.49
1546768048215.488048334.96
165112  
17523980485111.59 
18774180480156.1480481166.21
198018  
2081468047032.45 
2184188046837.838046977
2288698047426.62 
238883  
2490458047142.69 
2593588047574.82 
Data
Cell Formulas
RangeFormula
B2:B25,R2:R25B2=IFERROR(INDEX(Loans!$D$2:$D$27,MATCH($A2&IF(B$1="Loan ID 1","401L","401L2"),Loans!$A$2:$A$27&Loans!$B$2:$B$27,0)),"")



This is the Loans Tab
Book1
ABCD
1employee_idTypeLoan AmountLoan #
2102401L21.3480478
3202401L32.4580479
4220401L5.7580484
5287401L21.0780488
6609401L26.780472
7609401L231.1580473
8705401L103.180465
9705401L263.5180464
101409401L26.2280486
111586401L70.0380462
121586401L223.3680463
132709401L38.8180477
142709401L235.1880476
153889401L40.5180466
163889401L2147.4980467
174676401L15.4880482
184676401L234.9680483
195239401L111.5980485
207741401L156.1480480
217741401L2166.2180481
228146401L32.4580470
238418401L37.8380468
248418401L27780469
258869401L26.6280474
269045401L42.6980471
279358401L74.8280475
Loans
 
Last edited:
Upvote 0
When I copy & paste your speadsheet into a new worksheet the formula is there, but doesn't work. You think it might be a version Issue?
 
Upvote 0
The functions I used have been around for a long time. I don't think it is versions. I just think it is something small that you or I have missed.
You could try committing the formulas into the cells with the CSE keystroke (CNTL-SHFT-ENTR) combination, but that is for array functions which these are not.
You could also try taking the IFERROR function out (remember to take out the last argument - the <<,"")>> at the end. You'll get NA# errors but at least you'll see if it works where it is supposed to. And can do the long form error handling for the NA#'s later.

You named your sheets before pasting? Did you paste into new sheets or a new workbook?
What is the error message you are getting.



Can you verify that columns and rows of the mini worksheet I posted in POST #8 align with your data?

Can you use the xl2bb add in to paste a mini workbook like I have been doing?


I find it odd that you can't recreate the workbook that works by doing this:
1. Open New Book
2. Name Sheet "Loans"
3 Name another Sheet "Data"
4. Paste the Loans data first in the same starting cell (Loans!A1).
5. Past the Data data last in the same starting cell (Data!A1).
 
Last edited:
Upvote 0

Forum statistics

Threads
1,215,429
Messages
6,124,837
Members
449,193
Latest member
MikeVol

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