Hi Sri Reddy,
May be there is new line character before #, so when it reach to PI the last character # is dropped because including new line character the length is 30 characters i think(because windows CRLF in linux LF only), that is why in the file also after the description field all the field displaying in new line.
Regards,
Praveen.