Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
cac1231
 
Posts: n/a
Default Lookup from one spreadsheet that links to matching keys in another

I have header and detail type information, and would like to use the filter
function on the header spreadsheet then have the spreadsheet link to the
detail spreadsheet and just display the rows associated with the data in the
filter from the header.

Worst case I can combine the two spreadsheets into one via vlookup and just
repeat the header information for every detail line but would like to keep
the smaller file size associated with holding the data once.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
macropod
 
Posts: n/a
Default Lookup from one spreadsheet that links to matching keys in another

Hi cac,

If the aim is to minimise the target sheet's size, it would be best to do
all the filtering in a worksheet attached to the source workbook, then
simply use an external link that points to the source workbook's filtered
range.

As to how to construct the filtered table, you could use a formula like:
=INDEX(Data,MATCH(Criterion,UnfilteredCriteria,0))
for the first output row, which I'll assume to be row 2 (row 1 being a
heading row), and:
=IF(OR(A2="",COUNTA(A$2:A2)=COUNTIF(UnfilteredCrit eria,Criterion)),"",INDEX(
Data,MATCH(Criterion,OFFSET(UnfilteredCriteria,MAT CH(A2,Data,0),0,COUNT(Unfi
lteredCriteria)+1-MATCH(A2,Data,0),1),0)+MATCH(A2,Data,0)))
for row 3 and copied down as far as necessary.

You'll note that I've used three named ranges. Doing so makes it easier to
see what each part of the formula is referring to, though not necessarily a
whole lot easier to undestand. the 'Criterion' name refers to a single cell
that determines which cells from the 'UnfilteredCriteria' range to match
with, whilst 'Data' defines the range from which you actually want to
retrieve the corresponding contents.

Cheers


"cac1231" wrote in message
...
I have header and detail type information, and would like to use the

filter
function on the header spreadsheet then have the spreadsheet link to the
detail spreadsheet and just display the rows associated with the data in

the
filter from the header.

Worst case I can combine the two spreadsheets into one via vlookup and

just
repeat the header information for every detail line but would like to keep
the smaller file size associated with holding the data once.



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
Matching and Moving Data From One Spreadsheet to Another? [email protected] Excel Discussion (Misc queries) 1 March 18th 06 02:21 PM
Matching and Moving Data From One Spreadsheet to Another? [email protected] Excel Discussion (Misc queries) 1 March 18th 06 01:18 PM
Lookup function w/Text and Year Josh O. Excel Worksheet Functions 1 February 12th 05 11:27 PM
how do you change pathways (links) when consolidating spreadsheet. confused Excel Discussion (Misc queries) 0 December 9th 04 01:47 PM
double lookup, nest, or macro? Josef.angel Excel Worksheet Functions 1 October 29th 04 09:50 AM


All times are GMT +1. The time now is 03:04 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"