Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 90
Default Extracting the data according the number of cell (at specific range)

I have a minor Excel formula problem.

In my example has following data, cell A5 shows "apple", A6 shows "salt", A7
shows "sugar" and A8 shows "fish". On another hand, cell B3 is the
"criteria" data showing 3. My question is to form an Excel formula which can
extract the data from cell "A1" and then extract the 3rd data, which is
"sugar" (that is the result I want).

Althought the formula is counting from A1, but the excel formula know the
data after "apple" and "salt" is "sugar" (cell from A1 to A4 is empty),
because "sugar" is located on the 3rd in row!

I know this Excel formula, =INDIRECT("A"&B3), is working very perfect if I
want to scan the data in the WHOLE col A. How about if I have a situation
which the data ONLY located from A3 to A8, how to adjust the formula in order
it can accurately scan the data?

Please advice and thanks,
Wilchong

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...l-new/200805/1

  #2   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 15,768
Default Extracting the data according the number of cell (at specific range)

Here's one way...

Array entered** :

=INDEX(A1:A8,SMALL(IF(A1:A8<"",ROW(A1:A8)-MIN(ROW(A1:A8))+1),B3))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER)

Here's another way *IF* the data entered is *always* TEXT and is *always*
entered in a contiguous range:

=INDEX(A1:A8,MATCH("*",A1:A8,0)+B3-1)

--
Biff
Microsoft Excel MVP


"wilchong via OfficeKB.com" <u43231@uwe wrote in message
news:842bda5a27059@uwe...
I have a minor Excel formula problem.

In my example has following data, cell A5 shows "apple", A6 shows "salt",
A7
shows "sugar" and A8 shows "fish". On another hand, cell B3 is the
"criteria" data showing 3. My question is to form an Excel formula which
can
extract the data from cell "A1" and then extract the 3rd data, which is
"sugar" (that is the result I want).

Althought the formula is counting from A1, but the excel formula know the
data after "apple" and "salt" is "sugar" (cell from A1 to A4 is empty),
because "sugar" is located on the 3rd in row!

I know this Excel formula, =INDIRECT("A"&B3), is working very perfect if I
want to scan the data in the WHOLE col A. How about if I have a situation
which the data ONLY located from A3 to A8, how to adjust the formula in
order
it can accurately scan the data?

Please advice and thanks,
Wilchong

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...l-new/200805/1



  #3   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 90
Default Extracting the data according the number of cell (at specific range)

Hello T. Valko,
Many thanks for your advice. I am thinking if I want the excel formula scan
the data from A8 to A5 (from bottom to top, my early question is from top to
bottom), and cell B3 is still the "criteria" data showing 3.

Therefore, the result is "Salt". My question is that which parameter should
I revise in this formular

=INDEX(A3:A8,SMALL(IF(A3:A8<"",ROW(A3:A8)-MIN(ROW(A3:A8))+1),B1)).

Many thanks for your effort!
Wilchong




T. Valko wrote:
Here's one way...

Array entered** :

=INDEX(A1:A8,SMALL(IF(A1:A8<"",ROW(A1:A8)-MIN(ROW(A1:A8))+1),B3))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER)

Here's another way *IF* the data entered is *always* TEXT and is *always*
entered in a contiguous range:

=INDEX(A1:A8,MATCH("*",A1:A8,0)+B3-1)

I have a minor Excel formula problem.

[quoted text clipped - 18 lines]
Please advice and thanks,
Wilchong


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...l-new/200805/1

  #4   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 15,768
Default Extracting the data according the number of cell (at specific range)

Replace SMALL with LARGE.

=INDEX(A3:A8,LARGE(IF(A3:A8<"",ROW(A3:A8)-MIN(ROW(A3:A8))+1),B3))

Don't forget....array entered!

--
Biff
Microsoft Excel MVP


"wilchong via OfficeKB.com" <u43231@uwe wrote in message
news:843812846ebcd@uwe...
Hello T. Valko,
Many thanks for your advice. I am thinking if I want the excel formula
scan
the data from A8 to A5 (from bottom to top, my early question is from top
to
bottom), and cell B3 is still the "criteria" data showing 3.

Therefore, the result is "Salt". My question is that which parameter
should
I revise in this formular

=INDEX(A3:A8,SMALL(IF(A3:A8<"",ROW(A3:A8)-MIN(ROW(A3:A8))+1),B1)).

Many thanks for your effort!
Wilchong




T. Valko wrote:
Here's one way...

Array entered** :

=INDEX(A1:A8,SMALL(IF(A1:A8<"",ROW(A1:A8)-MIN(ROW(A1:A8))+1),B3))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER)

Here's another way *IF* the data entered is *always* TEXT and is *always*
entered in a contiguous range:

=INDEX(A1:A8,MATCH("*",A1:A8,0)+B3-1)

I have a minor Excel formula problem.

[quoted text clipped - 18 lines]
Please advice and thanks,
Wilchong


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...l-new/200805/1



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Extracting the data according to the number of cell wilchong via OfficeKB.com New Users to Excel 4 May 13th 08 02:28 AM
Extracting/deleting select data from range of cell DipyDawg Excel Discussion (Misc queries) 4 May 6th 08 06:48 PM
Count the number of times a cell value is within a specific range Everett Excel Worksheet Functions 4 September 2nd 06 10:54 PM
How to sum data that is only within a specific number range? ryesworld Excel Worksheet Functions 3 November 15th 05 10:23 PM
Extracting specific data from a cell Neil Bowen Excel Worksheet Functions 5 October 30th 05 04:33 PM


All times are GMT +1. The time now is 04:18 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"