View Single Post
  #4   Report Post  
Jason Morin
 
Posts: n/a
Default

With your shipment IDs in col. A and total samples shipped in col. B on
Sheet1, in a new sheet:

1. Copy the name of the first shipment ID into A1.
2. In A2 enter this an fill down until you see a 0:

=IF(COUNTIF($A$1:A1,A1)<VLOOKUP(A1,Sheet1!A:B,2,0) ,A1,INDEX(Sheet1!A:A,MATCH(A1,Sheet1!A:A,0)+1))

3. In B1 insert this and fill down:

=COUNTIF($A$1:A1,A1)

HTH
Jason
Atlanta, GA



"PPV" wrote:

My request sounds simple, but I have yet been unable to do it.

I have a worksheet with a column that has a shipment id, say "H-5"
I also have another column that lists the number of samples in that
shipment, say 3.

I need something that will create two new columns, one with the shipment id
and the other with the sample number. So based on the above entry it would
create three rows:
A B
1 H-5 1
2 H-5 2
3 H-5 3

Since there were three samples, it created three entries for each sample and
then would continue on for each entry on the original worksheet, say H-6,
five samples.

Any suggestions would be greatly appreciated.
Thanks,
-Derek