And apparently an even better solution is just putting the size in the format itself. No need to parse when you can just seek.
https://blog.kowalczyk.info/article/fc9203f7c72a4532b1ae51d0...
Did it multiple times and it works great, but companies you send raw data to often get huffy. So, back it goes into CSV or some poorly defined fixed width text file.
https://news.ycombinator.com/item?id=7474600