Finding a MAX and MIN value with criteria within a ALPHA-Numeric cloumnm

JChaney17

New Member
Joined
Feb 25, 2013
Messages
18
I am looking for a couple of formulas that will return a MAX and MIN value from a Alpha-numeric column with criteria. This is what I am looking at:

[TABLE="width: 221"]
<TBODY>[TR]
[TD]No.</SPAN>[/TD]
[TD]Tag No</SPAN>[/TD]
[TD]Type</SPAN>[/TD]
[/TR]
[TR]
[TD]1</SPAN>[/TD]
[TD]A001678</SPAN>[/TD]
[TD]P</SPAN>[/TD]
[/TR]
[TR]
[TD]2</SPAN>[/TD]
[TD]A001679</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]3</SPAN>[/TD]
[TD]A001680</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]4</SPAN>[/TD]
[TD]A001681</SPAN>[/TD]
[TD]P</SPAN>[/TD]
[/TR]
[TR]
[TD]5</SPAN>[/TD]
[TD]A001682</SPAN>[/TD]
[TD]E</SPAN>[/TD]
[/TR]
[TR]
[TD]6</SPAN>[/TD]
[TD]A001683</SPAN>[/TD]
[TD]E</SPAN>[/TD]
[/TR]
[TR]
[TD]7</SPAN>[/TD]
[TD]A001684</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]8</SPAN>[/TD]
[TD]A001685</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]9</SPAN>[/TD]
[TD]A001686</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]10</SPAN>[/TD]
[TD]A001687</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]11</SPAN>[/TD]
[TD]A001688</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]12</SPAN>[/TD]
[TD]A001689</SPAN>[/TD]
[TD]P</SPAN>[/TD]
[/TR]
[TR]
[TD]13</SPAN>[/TD]
[TD]A001690</SPAN>[/TD]
[TD]P</SPAN>[/TD]
[/TR]
[TR]
[TD]14</SPAN>[/TD]
[TD]A001691</SPAN>[/TD]
[TD]P</SPAN>[/TD]
[/TR]
[TR]
[TD]15</SPAN>[/TD]
[TD]A001692</SPAN>[/TD]
[TD]E</SPAN>[/TD]
[/TR]
[TR]
[TD]16</SPAN>[/TD]
[TD]A001693</SPAN>[/TD]
[TD]E</SPAN>[/TD]
[/TR]
[TR]
[TD]17</SPAN>[/TD]
[TD]A001694</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]18</SPAN>[/TD]
[TD]A001695</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]19</SPAN>[/TD]
[TD]A001696</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
[TR]
[TD]20</SPAN>[/TD]
[TD]A001697</SPAN>[/TD]
[TD]S</SPAN>[/TD]
[/TR]
</TBODY><COLGROUP><COL><COL><COL></COLGROUP>[/TABLE]

I am wanting to look for "S" in the "TYPE" column, and then have MAX and MIN formula's look for the MAX and MIN values in the "Tag No" column. I can get the number to display, but I would like to have the MAX and MIN values displayed as "A00####".

Any help would be appreciated.

Thanks.
 

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.
Hi

One formula option:


Excel 2007
ABCDEFGH
1No.Tag NoTypeSPE
21A001678PMaxA001697A001691A001693
32A001679SMinA001679A001678A001682
43A001680S
54A001681P
65A001682E
76A001683E
87A001684S
98A001685S
109A001686S
1110A001687S
1211A001688S
1312A001689P
1413A001690P
1514A001691P
1615A001692E
1716A001693E
1817A001694S
1918A001695S
2019A001696S
2120A001697S
Sheet3
Cell Formulas
RangeFormula
F2{=TEXT(MAX(IF($C$2:$C$21=F$1,MID($B$2:$B$21,2,255)+0)),"\A000000")}
F3{=TEXT(MIN(IF($C$2:$C$21=F$1,MID($B$2:$B$21,2,255)+0)),"\A000000")}
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
Thanks...that worked great. Since I am not real familiar with these formula's, can you tell me what the MID and the "2,255" are doing?
 
Upvote 0
The MID is used to remove the "A" from the value (leaving just numeric digits):

MID(A1,2,255)

Says take all characters from the second character (255 used because it will always be longer than the actual Tag No so will always capture the remaining characters).
 
Upvote 0

Forum statistics

Threads
1,223,239
Messages
6,170,947
Members
452,368
Latest member
jayp2104

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