IF/AND or VLOOKUP?

mjpish

New Member
Joined
Jun 25, 2014
Messages
4
I have a spreadsheet of physician names, clinic referred to and number referred in columns. I need to transfer that data to another sheet. So I need to search for specific physician at a specific clinic (they work in multiple clinics) and pull the value associated with that to another sheet. The other sheet has different formatting so I can't simply link or cut/paste. I was fiddling with IF/AND or VLOOKUP, but can't seem to figure how to get a VLOOKUP to just pull the visits if the doctor name matches and the clinic name matches. Any help would be appreciated.

Below is a small sampel of the spreadsheet, each doctor name would be repeated and associated with different clinics:

Physician</SPAN>
Visits</SPAN>
Clinic</SPAN>
ABOKA, ALEXANDER M [1421635]</SPAN>
11</SPAN>
DMC PT AMELIA IM</SPAN>
ALADE, FOLASHADE O [8310]</SPAN>
1</SPAN>
DMC PT AMELIA IM</SPAN>
ALBAND, WENDY F [8655]</SPAN>
1</SPAN>
DMC PT AMELIA IM</SPAN>
ANDERSON, ROBIN N [1415117]</SPAN>
1</SPAN>
DMC PT AMELIA IM</SPAN>
ANTOINE, ANGELA [1415120]</SPAN>
1</SPAN>
DMC PT AMELIA IM</SPAN>

<TBODY>
</TBODY>
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
There are several ways one if which is:


Excel 2010
ABC
1PhysicianVisitsClinic
2ABOKA, ALEXANDER M [1421635]11DMC PT AMELIA IM
3ALADE, FOLASHADE O [8310]1DMC PT AMELIA IM
4ALBAND, WENDY F [8655]1DMC PT AMELIA IM
5ANDERSON, ROBIN N [1415117]1DMC PT AMELIA IM
6ANTOINE, ANGELA [1415120]1DMC PT AMELIA IM
7
8
9
10
11ALBAND, WENDY F [8655]DMC PT AMELIA IM1
Sheet1
Cell Formulas
RangeFormula
C11{=INDEX($B$2:$B$6,MATCH(A11&B11,A2:A6&C2:C6,0))}
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
Seeing as the lookup value is numeric, this is another option:

Excel Workbook
ABC
1PhysicianVisitsClinic
2ABOKA, ALEXANDER M [1421635]11DMC PT AMELIA IM
3ALADE, FOLASHADE O [8310]1DMC PT AMELIA IM
4ALBAND, WENDY F [8655]1DMC PT AMELIA IM
5ANDERSON, ROBIN N [1415117]1DMC PT AMELIA IM
6ANTOINE, ANGELA [1415120]1DMC PT AMELIA IM
7
8
9ALBAND, WENDY F [8655]DMC PT AMELIA IM1
Sheet1
 
Upvote 0
Seeing as the lookup value is numeric, this is another option:

Sheet1

*ABC
1PhysicianVisitsClinic
2ABOKA, ALEXANDER M [1421635]11DMC PT AMELIA IM
3ALADE, FOLASHADE O [8310]1DMC PT AMELIA IM
4ALBAND, WENDY F [8655]1DMC PT AMELIA IM
5ANDERSON, ROBIN N [1415117]1DMC PT AMELIA IM
6ANTOINE, ANGELA [1415120]1DMC PT AMELIA IM
7***
8***
9ALBAND, WENDY F [8655]DMC PT AMELIA IM1

<COLGROUP><COL style="WIDTH: 30px; FONT-WEIGHT: bold"><COL style="WIDTH: 257px"><COL style="WIDTH: 159px"><COL style="WIDTH: 159px"></COLGROUP><TBODY>
</TBODY>

Spreadsheet Formulas
CellFormula
C9=SUMIFS($B$1:$B$6,$A$1:$A$6,A9,$C$1:$C$6,B9)

<TBODY>
</TBODY>

<TBODY>
</TBODY>


Excel tables to the web >> Excel Jeanie HTML 4

Thanks so much to both comments above!

I am having some trouble with that formula calling to another sheet within the same excel workbook:

=SUMIFS('Mel template'!C1:C1535,'Mel template'!B1:B1545,'Mel detail template'!A1058,'Mel template'!A1:A1535,'Mel detail template'!C6)

C colum is visits, B column is doctor, A column is clinic

It does not seem to recognize the 'Mel template! in the formula, it only puts in color and seems to recognize the links to the same sheet 'Mel detail template!

Does the results row need to be setup in order or can each cell be called to as formula above does with 'Mel detail template - for Dr name and Clinic name?
 
Upvote 0
Hi, does this help?

If not - what cells on the sheet where you are putting the formula contain the Clinic and Doctor that you want to look up on the "Template" sheet?

Excel Workbook
ABC
1ClinicPhysicianVisits
2DMC PT AMELIA IMALBAND, WENDY F [8655]1
Other
Excel Workbook
ABC
1ClinicPhysicianVisits
2DMC PT AMELIA IMABOKA, ALEXANDER M [1421635]11
3DMC PT AMELIA IMALADE, FOLASHADE O [8310]1
4DMC PT AMELIA IMALBAND, WENDY F [8655]1
5DMC PT AMELIA IMANDERSON, ROBIN N [1415117]1
6DMC PT AMELIA IMANTOINE, ANGELA [1415120]1
Mel template
 
Upvote 0
Hi, does this help?

If not - what cells on the sheet where you are putting the formula contain the Clinic and Doctor that you want to look up on the "Template" sheet?

Other

*ABC
1ClinicPhysicianVisits
2DMC PT AMELIA IMALBAND, WENDY F [8655]1

<COLGROUP><COL style="WIDTH: 30px; FONT-WEIGHT: bold"><COL style="WIDTH: 175px"><COL style="WIDTH: 220px"><COL style="WIDTH: 64px"></COLGROUP><TBODY>
</TBODY>

Spreadsheet Formulas
CellFormula
C2=SUMIFS('Mel template'!C:C,'Mel template'!A:A,A2,'Mel template'!B:B,B2)

<TBODY>
</TBODY>

<TBODY>
</TBODY>


Mel template

*ABC
1ClinicPhysicianVisits
2DMC PT AMELIA IMABOKA, ALEXANDER M [1421635]11
3DMC PT AMELIA IMALADE, FOLASHADE O [8310]1
4DMC PT AMELIA IMALBAND, WENDY F [8655]1
5DMC PT AMELIA IMANDERSON, ROBIN N [1415117]1
6DMC PT AMELIA IMANTOINE, ANGELA [1415120]1

<COLGROUP><COL style="WIDTH: 30px; FONT-WEIGHT: bold"><COL style="WIDTH: 159px"><COL style="WIDTH: 242px"><COL style="WIDTH: 58px"></COLGROUP><TBODY>
</TBODY>


Excel tables to the web >> Excel Jeanie HTML 4

Problem solved! I needed to matchup the ranges for each column exactly and it gave me what I needed! Thanks so much :)
 
Upvote 0

Forum statistics

Threads
1,215,461
Messages
6,124,953
Members
449,198
Latest member
MhammadishaqKhan

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