Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Jim
 
Posts: n/a
Default Lookup: Multiple Occurances

If I have a worksheet with serial number and date, how can I lookup the
entries from another sheet and display ALL the entrys.

1234 01/08/2005
1235 02/08/2005
1236 04/08/2005
1234 06/09/2005
1236 03/09/2005
1236 10/10/2005

For example on a second sheet if I look up the serial I need this sheet to
display ALL entries relating to that serial?
i.e
1234 01/08/2005
06/09/2005

or
1238 04/08/2005

or
1236 04/08/2005
03/09/2005
10/10/2005

etc




  #2   Report Post  
Peo Sjoblom
 
Posts: n/a
Default

One possible way

=INDEX('another sheet'!$B$1:$B$100,SMALL(IF('another
sheet'!$A$1:$A$100=$B$1,ROW('another sheet'!$A$1:$A$100)),ROW(1:1)))

where B1 holds the serial number to lookup, A1:A100 the serial numbers and
B1:B100 the dates

enter with ctrl + shift & enter

copy down until you get an error


--
Regards,

Peo Sjoblom

(No private emails please)


"Jim" <Jim wrote in message
k...
If I have a worksheet with serial number and date, how can I lookup the
entries from another sheet and display ALL the entrys.

1234 01/08/2005
1235 02/08/2005
1236 04/08/2005
1234 06/09/2005
1236 03/09/2005
1236 10/10/2005

For example on a second sheet if I look up the serial I need this sheet
to display ALL entries relating to that serial?
i.e
1234 01/08/2005
06/09/2005

or
1238 04/08/2005

or
1236 04/08/2005
03/09/2005
10/10/2005

etc





  #3   Report Post  
Alan Beban
 
Posts: n/a
Default Lookup: Multiple Occurances

Another way, if the functions in the freely downloadable file at
http://home.pacbell.net/beban are available to your workbook:

=VLookups(1234,A1:B100,2) array entered into a column of cells
sufficient to accommodate the number of occurrences.

Alan Beban

Peo Sjoblom wrote:
One possible way

=INDEX('another sheet'!$B$1:$B$100,SMALL(IF('another
sheet'!$A$1:$A$100=$B$1,ROW('another sheet'!$A$1:$A$100)),ROW(1:1)))

where B1 holds the serial number to lookup, A1:A100 the serial numbers
and B1:B100 the dates

enter with ctrl + shift & enter

copy down until you get an error


  #4   Report Post  
Ashish Mathur
 
Posts: n/a
Default Lookup: Multiple Occurances

Hi,

Assuming your list is in range A1:B7, enter the serial number for whivh you
want the data returned in A10. Now enter the following array formula
(Ctrl+Shift+Enter) in B10 and copy downwards

IF(ISERROR(INDEX($A$1:$B$7,SMALL(IF($A$1:$A$7=$A$1 0,ROW($A$1:$A$7)),ROW(1:1)),2)),"",INDEX($A$1:$B$7 ,SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$7)),ROW(1:1) ),2))

Regards,

Ashish Mathur

"Jim" wrote:

If I have a worksheet with serial number and date, how can I lookup the
entries from another sheet and display ALL the entrys.

1234 01/08/2005
1235 02/08/2005
1236 04/08/2005
1234 06/09/2005
1236 03/09/2005
1236 10/10/2005

For example on a second sheet if I look up the serial I need this sheet to
display ALL entries relating to that serial?
i.e
1234 01/08/2005
06/09/2005

or
1238 04/08/2005

or
1236 04/08/2005
03/09/2005
10/10/2005

etc





  #5   Report Post  
Biff
 
Posts: n/a
Default Lookup: Multiple Occurances

Hi!

A couple of pointers:

IF(ISERROR(INDEX($A$1:$B$7,SMALL(IF($A$1:$A$7=$A$1 0,ROW($A$1:$A$7)),ROW(1:1)),2)),"",INDEX
($A$1:$B$7,SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$7 )),ROW(1:1)),2))


There's no need to index both columns A and B since you're only interested
in and going to return data from a single column.

Also, you don't need to include the Index at all in the error trap. Any
error generated by the formula will come from this portion:

SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$7)),ROW(1:1))

So, with those suggestions the formula would be:

IF(ISERROR(SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$7) ),ROW(1:1))),"",INDEX($A$1:$A$7,SMALL(IF($A$1:$A$7 =$A$10,ROW($A$1:$A$7)),ROW(1:1))))

Biff

"Ashish Mathur" wrote in message
...
Hi,

Assuming your list is in range A1:B7, enter the serial number for whivh
you
want the data returned in A10. Now enter the following array formula
(Ctrl+Shift+Enter) in B10 and copy downwards

IF(ISERROR(INDEX($A$1:$B$7,SMALL(IF($A$1:$A$7=$A$1 0,ROW($A$1:$A$7)),ROW(1:1)),2)),"",INDEX($A$1:$B$7 ,SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$7)),ROW(1:1) ),2))

Regards,

Ashish Mathur

"Jim" wrote:

If I have a worksheet with serial number and date, how can I lookup the
entries from another sheet and display ALL the entrys.

1234 01/08/2005
1235 02/08/2005
1236 04/08/2005
1234 06/09/2005
1236 03/09/2005
1236 10/10/2005

For example on a second sheet if I look up the serial I need this sheet
to
display ALL entries relating to that serial?
i.e
1234 01/08/2005
06/09/2005

or
1238 04/08/2005

or
1236 04/08/2005
03/09/2005
10/10/2005

etc









  #6   Report Post  
Aladin Akyurek
 
Posts: n/a
Default Lookup: Multiple Occurances

You need to replace ROW(1:1) with something else for robustness. The
idiom is not efficient when the range to process is very large, a point
I felt to point out at some occasions as in http://tinyurl.com/b6zk7.

Biff wrote:
Hi!

A couple of pointers:


IF(ISERROR(INDEX($A$1:$B$7,SMALL(IF($A$1:$A$7=$A $10,ROW($A$1:$A$7)),ROW(1:1)),2)),"",INDEX
($A$1:$B$7,SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$ 7)),ROW(1:1)),2))



There's no need to index both columns A and B since you're only interested
in and going to return data from a single column.

Also, you don't need to include the Index at all in the error trap. Any
error generated by the formula will come from this portion:

SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$7)),ROW(1:1))

So, with those suggestions the formula would be:

IF(ISERROR(SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$7) ),ROW(1:1))),"",INDEX($A$1:$A$7,SMALL(IF($A$1:$A$7 =$A$10,ROW($A$1:$A$7)),ROW(1:1))))

Biff

"Ashish Mathur" wrote in message
...

Hi,

Assuming your list is in range A1:B7, enter the serial number for whivh
you
want the data returned in A10. Now enter the following array formula
(Ctrl+Shift+Enter) in B10 and copy downwards

IF(ISERROR(INDEX($A$1:$B$7,SMALL(IF($A$1:$A$7=$A $10,ROW($A$1:$A$7)),ROW(1:1)),2)),"",INDEX($A$1:$B $7,SMALL(IF($A$1:$A$7=$A$10,ROW($A$1:$A$7)),ROW(1: 1)),2))

Regards,

Ashish Mathur

"Jim" wrote:


If I have a worksheet with serial number and date, how can I lookup the
entries from another sheet and display ALL the entrys.

1234 01/08/2005
1235 02/08/2005
1236 04/08/2005
1234 06/09/2005
1236 03/09/2005
1236 10/10/2005

For example on a second sheet if I look up the serial I need this sheet
to
display ALL entries relating to that serial?
i.e
1234 01/08/2005
06/09/2005

or
1238 04/08/2005

or
1236 04/08/2005
03/09/2005
10/10/2005

etc









--

[1] The SumProduct function should implicitly coerce the truth values to
their Excel numeric equivalents.
[2] The lookup functions should have an optional argument for the return
value, defaulting to #N/A in its absence.
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
Conditional Lookup on Multiple Criteria TBarker Excel Worksheet Functions 1 June 22nd 05 12:28 AM
Formula checking multiple worksheets sonic-the-mouse Excel Worksheet Functions 2 June 5th 05 07:48 PM
Multiple lookup value's rucker31 Excel Worksheet Functions 0 March 11th 05 11:17 PM
Multiple Criteria Lookup Question Gregg Riemer Excel Discussion (Misc queries) 3 February 22nd 05 01:18 AM
Return Multiple Results with Lookup Josh O. Excel Worksheet Functions 1 February 4th 05 08:07 PM


All times are GMT +1. The time now is 02:24 PM.

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

About Us

"It's about Microsoft Excel"