in reply to Split file using perl and regexp
... or into hiring a programmer?
You've outlined, by example, a longish spec ...but haven't shown any hint of an attempt to solve your problem, even though you've asked similar questions at least 3 times in the past 60 days.
Where's your code? Precisely, what's wrong with it?
In Section
Seekers of Perl Wisdom