I'm looking forward to trying this completely CTE based tally table. My impression is that this script is going to be very fast for what it is. I'll let you know how it performs with some big data sets when I start implementing in a week or two. Thank you.