The database idea is interesting.
In reply to Re^2: Output should have multiple segments by John M. Dlugosz in thread Output should have multiple segments by John M. Dlugosz