On Dec 9, 2012, at 3:17 AM, Glen Bojsza wrote: > In other words the two values found in column 2 of the group data must then > get the corresponding column1 values from the original dataset. Hi, Glen. You'll get that if you remove the line "put 0 into tLineNumber" near the end of the repeat loop. Yes, variable "pLines" holds your original dataset. -- Dick