Thanks for that solution. It works perfectly except my data set goes back to 1 after each day (Variable2). The data below shows how the last number in the Variable2 column doesn't get retained but goes to 0. Date Date_Time Variable1 Variable2 20JUL2016 20JUL16:00:19:26 0.0509201597 124 20JUL2016 20JUL16:00:19:27 0.054355847 124 20JUL2016 20JUL16:00:19:28 0.051141817 124 20JUL2016 20JUL16:00:19:29 0.0469164758 124 . 20JUL16:00:19:29 . 125 20JUL2016 20JUL16:00:19:30 0.0441457602 0 20JUL2016 20JUL16:00:19:31 0.0492992911 0 20JUL2016 20JUL16:00:19:32 0.0641364728 0 20JUL2016 20JUL16:00:19:33 0.0691930286 0 20JUL2016 20JUL16:00:19:34 0.0612133679 0 20JUL2016 20JUL16:00:19:35 0.0720607192 0 Any idea on how to fix this? In addition, do you have any code that will sum Variable1 for each Variable2 and Date. Ie 20Jul2016 1 10.5 20Jul2016 2 11 20Jul2016 3 7 ..... 21Jul2016 1 8.5 etc
... View more