View Single Post
  #5   Report Post  
Random Poster
 
Posts: n/a
Default Returning row # using match or index of repeated text in a complex table

"General" wrote in news:1129841369.520961.179420
@g49g2000cwa.googlegroups.com:

Hi RP,

The data is spit out by an outside program, and the format can't be
changed.

Use of VB is not an option.

Thx,

Phil




Phil,

Insert a row so that the data starts in A2.

Put the following formula in the second row of an empty column (change B1
to reflect the actual column used) and then copy it down.

=IF(OR(LEFT(A2,1)="Q",A2=""),B1,A2)

Now you can use the two column match. Actually, you could append the
contents of A2 after the IF function. Then you could just use a regular
MATCH and avoid the array formula.

This formula assumes any non-blank cell that does not begin with a 'Q' is
a company name. The first argument would need to be refined if this is
not the case (i.e. you have companies that start with 'Q'). This should
get you going though.


HTH,
RP