Thank you both for your suggestions. They are much appreciated. As a general question if anyone would like to answer ... I know that theres 'more than one way to do it in perl, but is the approach I used a reasonably sensible one in your opinion?
Thanks again